Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 357e2263 authored by Steve Kondik's avatar Steve Kondik Committed by Steve Kondik
Browse files

cmsdk: Start external services at the right time

 * External services were being initialized when everyone else is
   handling systemReady. This makes it impossible to use an external
   service from somewhere like DisplayPowerController.

Change-Id: I6597081e7463077a1fa51957a3a67780588cfe86
parent 1eb8774e
Loading
Loading
Loading
Loading
+10 −9
Original line number Original line Diff line number Diff line
@@ -1122,6 +1122,16 @@ public final class SystemServer {
        // MMS service broker
        // MMS service broker
        mmsService = mSystemServiceManager.startService(MmsServiceBroker.class);
        mmsService = mSystemServiceManager.startService(MmsServiceBroker.class);


        // Externally-defined services
        for (String service : externalServices) {
            try {
                Slog.i(TAG, service);
                mSystemServiceManager.startService(service);
            } catch (Throwable e) {
                Slog.e(TAG, "Failure starting " + service , e);
            }
        }

        // It is now time to start up the app processes...
        // It is now time to start up the app processes...


        try {
        try {
@@ -1190,15 +1200,6 @@ public final class SystemServer {
            }
            }
        }
        }


        for (String service : externalServices) {
            try {
                Slog.i(TAG, service);
                mSystemServiceManager.startService(service);
            } catch (Throwable e) {
                Slog.e(TAG, "Failure starting " + service , e);
            }
        }

        if (gestureService != null) {
        if (gestureService != null) {
            try {
            try {
                gestureService.systemReady();
                gestureService.systemReady();