diff options
author | Jeff Brown <jeffbrown@google.com> | 2014-05-20 17:17:10 -0700 |
---|---|---|
committer | Jeff Brown <jeffbrown@google.com> | 2014-05-20 17:17:10 -0700 |
commit | 27736f5c0ada99bf2a7e007a1dec0ad51f65fa52 (patch) | |
tree | 828a6f00a30a6fe7b02d5390c904c84897688b1f /core/res | |
parent | e0d6a6b05b0861a5aa6dd8189de61a4da8d39dae (diff) | |
download | frameworks_base-27736f5c0ada99bf2a7e007a1dec0ad51f65fa52.zip frameworks_base-27736f5c0ada99bf2a7e007a1dec0ad51f65fa52.tar.gz frameworks_base-27736f5c0ada99bf2a7e007a1dec0ad51f65fa52.tar.bz2 |
Allow display timeouts to be set in config.xml.
Bug: 13671523
Change-Id: I79fc21999bc62743178d2d22071455a0c11070c9
Diffstat (limited to 'core/res')
-rw-r--r-- | core/res/res/values/config.xml | 43 | ||||
-rw-r--r-- | core/res/res/values/symbols.xml | 3 |
2 files changed, 46 insertions, 0 deletions
diff --git a/core/res/res/values/config.xml b/core/res/res/values/config.xml index 9d27164..dd13db0 100644 --- a/core/res/res/values/config.xml +++ b/core/res/res/values/config.xml @@ -1181,6 +1181,49 @@ --> <bool name="config_powerDecoupleInteractiveModeFromDisplay">false</bool> + <!-- User activity timeout: Minimum screen off timeout in milliseconds. + + Sets a lower bound for the {@link Settings.System#SCREEN_OFF_TIMEOUT} setting + which determines how soon the device will go to sleep when there is no + user activity. + + This value must be greater than zero, otherwise the device will immediately + fall asleep again as soon as it is awoken. + --> + <integer name="config_minimumScreenOffTimeout">10000</integer> + + <!-- User activity timeout: Maximum screen dim duration in milliseconds. + + Sets an upper bound for how long the screen will dim before the device goes + to sleep when there is no user activity. The dim duration is subtracted from + the overall screen off timeout to determine the screen dim timeout. + When the screen dim timeout expires, the screen will dim, shortly thereafter + the device will go to sleep. + + If the screen off timeout is very short, the dim duration may be reduced + proportionally. See config_maximumScreenDimRatio. + + This value may be zero in which case the screen will not dim before the + device goes to sleep. + --> + <integer name="config_maximumScreenDimDuration">7000</integer> + + <!-- User activity timeout: Maximum screen dim duration as a percentage of screen off timeout. + + This resource is similar to config_maximumScreenDimDuration but the maximum + screen dim duration is defined as a ratio of the overall screen off timeout + instead of as an absolute value in milliseconds. This is useful for reducing + the dim duration when the screen off timeout is very short. + + When computing the screen dim duration, the power manager uses the lesser + of the effective durations expressed by config_maximumScreenDimDuration and + config_maximumScreenDimRatio. + + This value must be between 0% and 100%. If the value is zero, the screen will not + dim before the device goes to sleep. + --> + <fraction name="config_maximumScreenDimRatio">20%</fraction> + <!-- Base "touch slop" value used by ViewConfiguration as a movement threshold where scrolling should begin. --> <dimen name="config_viewConfigurationTouchSlop">8dp</dimen> diff --git a/core/res/res/values/symbols.xml b/core/res/res/values/symbols.xml index 72ff32f..29ac8de 100644 --- a/core/res/res/values/symbols.xml +++ b/core/res/res/values/symbols.xml @@ -1633,6 +1633,9 @@ <java-symbol type="string" name="enable_explore_by_touch_warning_message" /> <java-symbol type="bool" name="config_powerDecoupleAutoSuspendModeFromDisplay" /> <java-symbol type="bool" name="config_powerDecoupleInteractiveModeFromDisplay" /> + <java-symbol type="integer" name="config_minimumScreenOffTimeout" /> + <java-symbol type="integer" name="config_maximumScreenDimDuration" /> + <java-symbol type="fraction" name="config_maximumScreenDimRatio" /> <java-symbol type="string" name="config_customAdbPublicKeyConfirmationComponent" /> <java-symbol type="layout" name="resolver_list" /> |