summaryrefslogtreecommitdiff
path: root/services/java/com/android/server/PowerManagerService.java
diff options
context:
space:
mode:
authorJeff Brown <jeffbrown@google.com>2012-04-30 14:58:40 -0700
committerJeff Brown <jeffbrown@google.com>2012-04-30 15:48:42 -0700
commitc458ce98ce42c00b98afe00670f822814f3da572 (patch)
treec993b6f8b3361f2ee1116f76709427e6106bd875 /services/java/com/android/server/PowerManagerService.java
parent3ea8761974a530218a246dc73583c8820b12bf0b (diff)
Add support for using the lid switch to turn off the screen.
Added a config option to allow the lid switch to turn off the screen. This is a closer match to what a lid switch should be doing. Removed an old feature to bypass keyguard when keyboard is visible because the way it was plumbed in made bad assumptions about the meaning of the lid switch. Also, the last product we shipped that had a physical keyboard turned this config option off. So away it goes. We can bring it back someday if we really want it. It's questionable how useful the feature is anyhow, since it only works when the keyguard is unsecure and when the lid switch is unlikely to be jostled in the user's pocket. Fixed a bug where we would tell the power manager that the keyboard was visible even if the lid switch did not control the keyboard. This used to cause the power manager to try to set the keyboard brightness, which doesn't work. Bug: 6377115 Bug: 6406726 Change-Id: Ic84b71d09563d51c92cd1cf132fa8bdee6509103
Diffstat (limited to 'services/java/com/android/server/PowerManagerService.java')
-rw-r--r--services/java/com/android/server/PowerManagerService.java3
1 files changed, 2 insertions, 1 deletions
diff --git a/services/java/com/android/server/PowerManagerService.java b/services/java/com/android/server/PowerManagerService.java
index 9a371c6c5539..bd50e227df37 100644
--- a/services/java/com/android/server/PowerManagerService.java
+++ b/services/java/com/android/server/PowerManagerService.java
@@ -2521,7 +2521,8 @@ public class PowerManagerService extends IPowerManager.Stub
return val;
} catch (Exception e) {
// guard against null pointer or index out of bounds errors
- Slog.e(TAG, "getAutoBrightnessValue", e);
+ Slog.e(TAG, "Values array must be non-empty and must be the same length "
+ + "as the auto-brightness levels array. Check config.xml.", e);
return 255;
}
}