Add service to monitor/control the flow of data.
bug:2576057 Change-Id: Ib343c7ee1d619c6978910d9ee597db195d5aa3b6
This commit is contained in:
@@ -99,6 +99,7 @@ class ServerThread extends Thread {
|
||||
DockObserver dock = null;
|
||||
UiModeManagerService uiMode = null;
|
||||
RecognitionManagerService recognition = null;
|
||||
ThrottleService throttle = null;
|
||||
|
||||
// Critical services...
|
||||
try {
|
||||
@@ -268,6 +269,15 @@ class ServerThread extends Thread {
|
||||
Slog.e(TAG, "Failure starting Connectivity Service", e);
|
||||
}
|
||||
|
||||
try {
|
||||
Slog.i(TAG, "Throttle Service");
|
||||
throttle = new ThrottleService(context);
|
||||
ServiceManager.addService(
|
||||
Context.THROTTLE_SERVICE, throttle);
|
||||
} catch (Throwable e) {
|
||||
Slog.e(TAG, "Failure starting ThrottleService", e);
|
||||
}
|
||||
|
||||
try {
|
||||
Slog.i(TAG, "Accessibility Manager");
|
||||
ServiceManager.addService(Context.ACCESSIBILITY_SERVICE,
|
||||
@@ -457,6 +467,7 @@ class ServerThread extends Thread {
|
||||
final BatteryService batteryF = battery;
|
||||
final ConnectivityService connectivityF = connectivity;
|
||||
final DockObserver dockF = dock;
|
||||
final ThrottleService throttleF = throttle;
|
||||
final UiModeManagerService uiModeF = uiMode;
|
||||
final AppWidgetService appWidgetF = appWidget;
|
||||
final WallpaperManagerService wallpaperF = wallpaper;
|
||||
@@ -488,6 +499,7 @@ class ServerThread extends Thread {
|
||||
if (wallpaperF != null) wallpaperF.systemReady();
|
||||
if (immF != null) immF.systemReady();
|
||||
if (locationF != null) locationF.systemReady();
|
||||
if (throttleF != null) throttleF.systemReady();
|
||||
}
|
||||
});
|
||||
|
||||
|
||||
Reference in New Issue
Block a user