How to keep display in permanent unlock and full brightness state in Android

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

How to keep display in permanent unlock and full brightness state in Android

3,180件の閲覧回数
Swamy
Contributor III

Hi All,

1).

Please let me know how to stop display going to lock state (lock state options:15sec, 30sec, 1m, 2m, 10m, 30m).

2).

I also want to keep the display in permanent full brightness mode.

Please suggest

Regards,

Swamy

ラベル(1)
タグ(2)
0 件の賞賛
返信
4 返答(返信)

1,821件の閲覧回数
Swamy
Contributor III

Thanks Alan.

Thanks Tom, I have modified the code..I will check and update.

Niki,

Thanks for the response.

Is it possible to tell me which source file I need to add this code mentioned in the link, As I am new to this Android, I am not much aware of the android source tree.

Regards,

Swamy

0 件の賞賛
返信

1,821件の閲覧回数
nww
Contributor I

most likely you want to do this as mentioned above.

anyhow, there is a way to do it in software. you can write a service that creates a wakelock: http://developer.android.com/reference/android/os/PowerManager.html

0 件の賞賛
返信

1,821件の閲覧回数
t_heyligen
Contributor I

Hi Swamy,

If you would like to achieve 1) without having the device attached to the host:


The default for "display sleep" can be found in file frameworks/base/packages/SettingsProvider/res/values/defaults.xml.

Look for def_screen_off_timeout and change its value to -1, meaning "Never".

Also, add "Never" and "-1" to the screen_timeout_entries and screen_timeout_values in file packages/apps/Settings/res/values/arrays.xml. This way, "Never" will also appear as an option in the Settings GUI.
Best regards,
  Tom.
0 件の賞賛
返信

1,821件の閲覧回数
AlanLevy
Contributor I

1) Settings -> Applications -> Development -> Stay awake

2) I think this probably requires a code change.

0 件の賞賛
返信