Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

hidden flows and custom toc removed from non-touch devices #11690

Merged
merged 5 commits into from
Apr 18, 2024
Merged
Changes from 4 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
5 changes: 5 additions & 0 deletions frontend/apps/reader/modules/readerhandmade.lua
Original file line number Diff line number Diff line change
@@ -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")
Expand Down Expand Up @@ -119,6 +120,10 @@ function ReaderHandMade:onToggleHandmadeFlows()
end

function ReaderHandMade:addToMainMenu(menu_items)
-- As it's currently impossible to create custom hidden flows on non-touch, and really impractical to create custom toc, better hide these features completely
Frenzie marked this conversation as resolved.
Show resolved Hide resolved
if not Device:isTouchDevice() then
return
Commodore64user marked this conversation as resolved.
Show resolved Hide resolved
end
menu_items.handmade_toc = {
text = _("Custom table of contents") .. " " .. self.custom_toc_symbol,
checked_func = function() return self.toc_enabled end,
Expand Down