[feat] Kindle suspend using lipc (#4825)
Fixes problems with making Kindle go to sleep using menu or gesture manager action.
This commit is contained in:
1 parent
d58774b875
commit
5f44ef5dad
2 files changed
+7
-1
No files matched your search
@@ -89,4 +89,10 @@ function KindlePowerD:afterResume()
|
||||
end
|
||||
end
|
||||
|
||||
function KindlePowerD:toggleSuspend()
|
||||
if self.lipc_handle then
|
||||
self.lipc_handle:set_int_property("com.lab126.powerd", "powerButton", 1)
|
||||
end
|
||||
end
|
||||
|
||||
return KindlePowerD
|
||||
@@ -1109,7 +1109,7 @@ function UIManager:suspend()
|
||||
if Device:isCervantes() or Device:isKobo() or Device:isSDL() or Device:isSonyPRSTUX() then
|
||||
self.event_handlers["Suspend"]()
|
||||
elseif Device:isKindle() then
|
||||
self.event_handlers["IntoSS"]()
|
||||
Device.powerd:toggleSuspend()
|
||||
end
|
||||
end
|
||||
|
||||
|
||||
Reference in new issue
Block a user