summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rwxr-xr-xpackages/SystemUI/src/com/android/systemui/keyguard/KeyguardViewMediator.java4
1 files changed, 4 insertions, 0 deletions
diff --git a/packages/SystemUI/src/com/android/systemui/keyguard/KeyguardViewMediator.java b/packages/SystemUI/src/com/android/systemui/keyguard/KeyguardViewMediator.java
index 52661e6..2152ede6 100755
--- a/packages/SystemUI/src/com/android/systemui/keyguard/KeyguardViewMediator.java
+++ b/packages/SystemUI/src/com/android/systemui/keyguard/KeyguardViewMediator.java
@@ -632,6 +632,7 @@ public class KeyguardViewMediator extends SystemUI {
android.Manifest.permission.CONTROL_KEYGUARD, null);
mContext.registerReceiver(mBroadcastReceiver, new IntentFilter(KEYGUARD_SERVICE_ACTION_STATE_CHANGE),
android.Manifest.permission.CONTROL_KEYGUARD, null);
+ mContext.registerReceiver(mBroadcastReceiver, new IntentFilter(TelephonyManager.ACTION_PHONE_STATE_CHANGED));
mKeyguardDisplayManager = new KeyguardDisplayManager(mContext);
@@ -1379,6 +1380,9 @@ public class KeyguardViewMediator extends SystemUI {
} else {
mSettingsObserver.unobserve();
}
+ } else if (TelephonyManager.ACTION_PHONE_STATE_CHANGED.equals(intent.getAction())) {
+ mPhoneState = intent.getStringExtra(TelephonyManager.EXTRA_STATE);
+ if (DEBUG) Log.d(TAG, "phone state change, new state: " + mPhoneState);
}
}
};