From fe2bddfae1b8c2375f58216871d923cbfe267dd3 Mon Sep 17 00:00:00 2001 From: Dianne Hackborn Date: Sun, 20 Sep 2009 15:21:10 -0700 Subject: [PATCH] Don't wake up the screen as soon as the lid opens. We may need to wait until the lock screen is ready. Change-Id: Id114f4f37051680ab880056b4c989b1fa8aa02b3 --- services/java/com/android/server/PowerManagerService.java | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/services/java/com/android/server/PowerManagerService.java b/services/java/com/android/server/PowerManagerService.java index 656d6ba616fac..9d2fc2700e5e1 100644 --- a/services/java/com/android/server/PowerManagerService.java +++ b/services/java/com/android/server/PowerManagerService.java @@ -1862,9 +1862,10 @@ class PowerManagerService extends IPowerManager.Stub Log.d(TAG, "setKeyboardVisibility: " + visible); } mKeyboardVisible = visible; - // don't signal user activity when closing keyboard if the screen is off. - // otherwise, we want to make sure the backlights are adjusted. - if (visible || (mPowerState & SCREEN_ON_BIT) != 0) { + // don't signal user activity if the screen is off; other code + // will take care of turning on due to a true change to the lid + // switch and synchronized with the lock screen. + if ((mPowerState & SCREEN_ON_BIT) != 0) { userActivity(SystemClock.uptimeMillis(), false, BUTTON_EVENT, true); } }