Do not advance mLastEventTime when enabling or disabling user activity.
Fixes a race condition between the keyguard and power key that sometimes resulted in the power key failing to turn off the screen. Fixes bug b/2212852 (Power button does not put phone to sleep) Change-Id: I92498c5fddf2bfc32b105ea1a7ea14a06d83888e Signed-off-by: Mike Lockwood <lockwood@android.com>
This commit is contained in:
@ -2079,7 +2079,6 @@ class PowerManagerService extends IPowerManager.Stub
|
||||
public void enableUserActivity(boolean enabled) {
|
||||
synchronized (mLocks) {
|
||||
mUserActivityAllowed = enabled;
|
||||
mLastEventTime = SystemClock.uptimeMillis(); // we might need to pass this in
|
||||
}
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user