Several improvements of AutoFrontlight plugin and enable it by default (#2975)

* Force refresh when kindle is out of screensaver or usb is unpluged.

* Improve AutoFrontlight

* More plugins sub menu

* Last brightness should always be updated

* Finish autofrontlight improvement and enable it by default.

* More tets

* onFlushSettings

* MenuSorter can now correctly sort sub menus
This commit is contained in:
Hzj_jie
2017-06-24 00:55:31 -07:00
committed by Frans de Jonge
parent 808766b7f3
commit 970f2e7306
8 changed files with 208 additions and 57 deletions

View File

@@ -206,11 +206,12 @@ function Device:retrieveNetworkInfo()
end
-- Return an integer value to indicate the brightness of the environment. The value should be in
-- range [0, 3].
-- range [0, 4].
-- 0: dark.
-- 1: dim, frontlight is needed.
-- 2: bright, frontlight is not needed.
-- 3: dazzling.
-- 2: neutral, turning frontlight on or off does not impact the reading experience.
-- 3: bright, frontlight is not needed.
-- 4: dazzling.
function Device:ambientBrightnessLevel()
return 0
end