mirror of
https://github.com/koreader/koreader.git
synced 2025-08-10 00:52:38 +00:00
ReaderFooter: Refresh the footer on frontlight state changes issued by the frontlight widget (#9084)
c.f, https://www.mobileread.com/forums/showpost.php?p=4220159&postcount=7
This commit is contained in:
@@ -2473,8 +2473,12 @@ function ReaderFooter:maybeUpdateFooter()
|
||||
end
|
||||
|
||||
function ReaderFooter:onFrontlightStateChanged()
|
||||
if self.settings.frontlight then
|
||||
self:maybeUpdateFooter()
|
||||
-- Custom variant of maybeUpdateFooter that *also* whitelists the FL widget...
|
||||
local top_wg = UIManager:getTopWidget()
|
||||
if top_wg == "ReaderUI" or top_wg == "FrontLightWidget" then
|
||||
self:onUpdateFooter(self.view.footer_visible)
|
||||
else
|
||||
self:onUpdateFooter()
|
||||
end
|
||||
end
|
||||
|
||||
|
||||
Reference in New Issue
Block a user