mirror of
https://github.com/koreader/koreader.git
synced 2025-08-10 00:52:38 +00:00
Show only 1 End Document Dialog at a time
if scrolling past the end of a document the EndOfBook event get fired once per scroll (a lot)
This commit is contained in:
@@ -60,7 +60,7 @@ function ReaderStatus:onEndOfBook()
|
||||
self:onMarkBook(true)
|
||||
end
|
||||
|
||||
if settings == "pop-up" or settings == nil then
|
||||
if (settings == "pop-up" or settings == nil) and UIManager:getTopWidget() ~= "end_document" then
|
||||
local buttons = {
|
||||
{
|
||||
{
|
||||
@@ -128,6 +128,7 @@ function ReaderStatus:onEndOfBook()
|
||||
},
|
||||
}
|
||||
choose_action = ButtonDialogTitle:new{
|
||||
name = "end_document",
|
||||
title = _("You've reached the end of the document.\nWhat would you like to do?"),
|
||||
title_align = "center",
|
||||
buttons = buttons,
|
||||
|
||||
Reference in New Issue
Block a user