ReaderHighlight: fix long-pressing on image (#14048)
Some checks failed
macos / macOS 13 x86-64 🔨15.2 🎯10.15 (push) Has been cancelled
macos / macOS 14 ARM64 🔨15.4 🎯11.0 (push) Has been cancelled

This commit is contained in:
hius07
2025-07-12 20:29:41 +03:00
committed by GitHub
parent 655ba58ae5
commit c4c95a0e90

View File

@@ -1678,15 +1678,13 @@ function ReaderHighlight:onHold(arg, ges)
local image = self.ui.document:getImageFromPosition(self.hold_pos, true, true)
if image then
logger.dbg("hold on image")
self.hold_pos = nil
local ImageViewer = require("ui/widget/imageviewer")
local imgviewer = ImageViewer:new{
UIManager:show(ImageViewer:new{
image = image,
-- title_text = _("Document embedded image"),
-- No title, more room for image
with_title_bar = false,
with_title_bar = false, -- more room for image
fullscreen = true,
}
UIManager:show(imgviewer)
})
self:onStopHighlightIndicator()
return true
end