Track native processes and airplane mode.

Turn signal strengths on/off when toggling airplane mode.
This commit is contained in:
Amith Yamasani
2009-06-19 09:21:17 -07:00
parent 4133751d51
commit 32dbefda71
6 changed files with 83 additions and 13 deletions

View File

@ -462,6 +462,15 @@ class TelephonyRegistry extends ITelephonyRegistry.Stub {
//
private void broadcastServiceStateChanged(ServiceState state) {
long ident = Binder.clearCallingIdentity();
try {
mBatteryStats.noteAirplaneMode(state.getState() == ServiceState.STATE_POWER_OFF);
} catch (RemoteException re) {
// Can't do much
} finally {
Binder.restoreCallingIdentity(ident);
}
Intent intent = new Intent(TelephonyIntents.ACTION_SERVICE_STATE_CHANGED);
Bundle data = new Bundle();
state.fillInNotifierBundle(data);