summaryrefslogtreecommitdiffstats
path: root/packages/Keyguard
diff options
context:
space:
mode:
authorJorim Jaggi <jjaggi@google.com>2015-05-14 00:36:02 +0000
committerAndroid (Google) Code Review <android-gerrit@google.com>2015-05-14 00:36:03 +0000
commit6a587acd1dcaa0b0d58ff9ac58e8a2ebff0aa3be (patch)
tree6fc209c7ddfc4f7421e6eab6a6780d710f2dfdb8 /packages/Keyguard
parent1864460bf3c495e7821326f9753324247d4c778b (diff)
parentaa4d32add72fa728f9cfe4eeb014b26eb5d091c2 (diff)
downloadframeworks_base-6a587acd1dcaa0b0d58ff9ac58e8a2ebff0aa3be.zip
frameworks_base-6a587acd1dcaa0b0d58ff9ac58e8a2ebff0aa3be.tar.gz
frameworks_base-6a587acd1dcaa0b0d58ff9ac58e8a2ebff0aa3be.tar.bz2
Merge "Fix fingerprint for multiuser" into mnc-dev
Diffstat (limited to 'packages/Keyguard')
-rw-r--r--packages/Keyguard/src/com/android/keyguard/KeyguardUpdateMonitor.java54
1 files changed, 6 insertions, 48 deletions
diff --git a/packages/Keyguard/src/com/android/keyguard/KeyguardUpdateMonitor.java b/packages/Keyguard/src/com/android/keyguard/KeyguardUpdateMonitor.java
index 1cee642..5fece8d 100644
--- a/packages/Keyguard/src/com/android/keyguard/KeyguardUpdateMonitor.java
+++ b/packages/Keyguard/src/com/android/keyguard/KeyguardUpdateMonitor.java
@@ -100,7 +100,6 @@ public class KeyguardUpdateMonitor implements TrustManager.TrustListener {
private static final int MSG_SIM_STATE_CHANGE = 304;
private static final int MSG_RINGER_MODE_CHANGED = 305;
private static final int MSG_PHONE_STATE_CHANGED = 306;
- private static final int MSG_CLOCK_VISIBILITY_CHANGED = 307;
private static final int MSG_DEVICE_PROVISIONED = 308;
private static final int MSG_DPM_STATE_CHANGED = 309;
private static final int MSG_USER_SWITCHING = 310;
@@ -172,9 +171,6 @@ public class KeyguardUpdateMonitor implements TrustManager.TrustListener {
case MSG_PHONE_STATE_CHANGED:
handlePhoneStateChanged((String) msg.obj);
break;
- case MSG_CLOCK_VISIBILITY_CHANGED:
- handleClockVisibilityChanged();
- break;
case MSG_DEVICE_PROVISIONED:
handleDeviceProvisioned();
break;
@@ -756,15 +752,11 @@ public class KeyguardUpdateMonitor implements TrustManager.TrustListener {
public void onUserSwitching(int newUserId, IRemoteCallback reply) {
mHandler.sendMessage(mHandler.obtainMessage(MSG_USER_SWITCHING,
newUserId, 0, reply));
- mSwitchingUser = true;
- updateFingerprintListeningState();
}
@Override
public void onUserSwitchComplete(int newUserId) throws RemoteException {
mHandler.sendMessage(mHandler.obtainMessage(MSG_USER_SWITCH_COMPLETE,
newUserId, 0));
- mSwitchingUser = false;
- updateFingerprintListeningState();
}
@Override
public void onForegroundProfileSwitch(int newProfileId) {
@@ -869,6 +861,9 @@ public class KeyguardUpdateMonitor implements TrustManager.TrustListener {
* Handle {@link #MSG_USER_SWITCHING}
*/
protected void handleUserSwitching(int userId, IRemoteCallback reply) {
+ mSwitchingUser = true;
+ updateFingerprintListeningState();
+
for (int i = 0; i < mCallbacks.size(); i++) {
KeyguardUpdateMonitorCallback cb = mCallbacks.get(i).get();
if (cb != null) {
@@ -885,6 +880,9 @@ public class KeyguardUpdateMonitor implements TrustManager.TrustListener {
* Handle {@link #MSG_USER_SWITCH_COMPLETE}
*/
protected void handleUserSwitchComplete(int userId) {
+ mSwitchingUser = false;
+ updateFingerprintListeningState();
+
for (int i = 0; i < mCallbacks.size(); i++) {
KeyguardUpdateMonitorCallback cb = mCallbacks.get(i).get();
if (cb != null) {
@@ -1044,19 +1042,6 @@ public class KeyguardUpdateMonitor implements TrustManager.TrustListener {
}
/**
- * Handle {@link #MSG_CLOCK_VISIBILITY_CHANGED}
- */
- private void handleClockVisibilityChanged() {
- if (DEBUG) Log.d(TAG, "handleClockVisibilityChanged()");
- for (int i = 0; i < mCallbacks.size(); i++) {
- KeyguardUpdateMonitorCallback cb = mCallbacks.get(i).get();
- if (cb != null) {
- cb.onClockVisibilityChanged();
- }
- }
- }
-
- /**
* Handle {@link #MSG_KEYGUARD_VISIBILITY_CHANGED}
*/
private void handleKeyguardVisibilityChanged(int showing) {
@@ -1100,21 +1085,6 @@ public class KeyguardUpdateMonitor implements TrustManager.TrustListener {
}
}
- public boolean isKeyguardVisible() {
- return mKeyguardIsVisible;
- }
-
- /**
- * @return if the keyguard is currently in bouncer mode.
- */
- public boolean isKeyguardBouncer() {
- return mBouncer;
- }
-
- public boolean isSwitchingUser() {
- return mSwitchingUser;
- }
-
private static boolean isBatteryUpdateInteresting(BatteryStatus old, BatteryStatus current) {
final boolean nowPluggedIn = current.isPluggedIn();
final boolean wasPluggedIn = old.isPluggedIn();
@@ -1140,13 +1110,6 @@ public class KeyguardUpdateMonitor implements TrustManager.TrustListener {
}
/**
- * @return The default plmn (no service)
- */
- private CharSequence getDefaultPlmn() {
- return mContext.getResources().getText(R.string.keyguard_carrier_default);
- }
-
- /**
* Remove the given observer's callback.
*
* @param callback The callback to remove
@@ -1211,11 +1174,6 @@ public class KeyguardUpdateMonitor implements TrustManager.TrustListener {
message.sendToTarget();
}
- public void reportClockVisible(boolean visible) {
- mClockVisible = visible;
- mHandler.obtainMessage(MSG_CLOCK_VISIBILITY_CHANGED).sendToTarget();
- }
-
/**
* Report that the user successfully entered the SIM PIN or PUK/SIM PIN so we
* have the information earlier than waiting for the intent