|
|
|
@ -1,4 +1,5 @@
|
|
|
|
|
local ConfirmBox = require("ui/widget/confirmbox")
|
|
|
|
|
local Device = require("device")
|
|
|
|
|
local Event = require("ui/event")
|
|
|
|
|
local InfoMessage = require("ui/widget/infomessage")
|
|
|
|
|
local InputDialog = require("ui/widget/inputdialog")
|
|
|
|
@ -119,6 +120,7 @@ function ReaderHandMade:onToggleHandmadeFlows()
|
|
|
|
|
end
|
|
|
|
|
|
|
|
|
|
function ReaderHandMade:addToMainMenu(menu_items)
|
|
|
|
|
if Device:isTouchDevice() then
|
|
|
|
|
menu_items.handmade_toc = {
|
|
|
|
|
text = _("Custom table of contents") .. " " .. self.custom_toc_symbol,
|
|
|
|
|
checked_func = function() return self.toc_enabled end,
|
|
|
|
@ -298,6 +300,8 @@ Hidden flows are shown with gray or hatched background in Book map and Page brow
|
|
|
|
|
end,
|
|
|
|
|
}
|
|
|
|
|
end
|
|
|
|
|
end
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
function ReaderHandMade:updateHandmagePages()
|
|
|
|
|
if not self.ui.rolling then
|
|
|
|
@ -338,8 +342,10 @@ function ReaderHandMade:onDocumentRerendered()
|
|
|
|
|
-- Called with CRE document when partial rerendering not enabled
|
|
|
|
|
self:updateHandmagePages()
|
|
|
|
|
-- Don't have these send events their own events
|
|
|
|
|
if Device:isTouchDevice() then
|
|
|
|
|
self:setupFlows(true)
|
|
|
|
|
self:setupToc(true)
|
|
|
|
|
end
|
|
|
|
|
-- ReaderToc will process this event just after us, and will
|
|
|
|
|
-- call its onUpdateToc: we don't need to send it.
|
|
|
|
|
-- (Also, no need for InitScrollPageStates with CRE.)
|
|
|
|
|