mirror of
https://github.com/koreader/koreader.git
synced 2025-08-10 00:52:38 +00:00
Annotations: fixes (#11761)
This commit is contained in:
@@ -26,6 +26,11 @@ function ReaderAnnotation:buildAnnotation(bm, highlights, init)
|
||||
end
|
||||
pageno = self.ui.paging and bm.page or self.document:getPageFromXPointer(bm.page)
|
||||
end
|
||||
if self.ui.paging and bm.pos0 and not bm.pos0.page then
|
||||
-- old single-page reflow highlights do not have page in position
|
||||
bm.pos0.page = bm.page
|
||||
bm.pos1.page = bm.page
|
||||
end
|
||||
if not hl then -- page bookmark or orphaned bookmark
|
||||
hl = {}
|
||||
if bm.highlighted then -- orphaned bookmark
|
||||
@@ -40,13 +45,6 @@ function ReaderAnnotation:buildAnnotation(bm, highlights, init)
|
||||
end
|
||||
end
|
||||
end
|
||||
if self.ui.paging then
|
||||
-- old single-page reflow highlights do not have page in position
|
||||
if not bm.pos0.page then
|
||||
bm.pos0.page = bm.page
|
||||
bm.pos1.page = bm.page
|
||||
end
|
||||
end
|
||||
return { -- annotation
|
||||
datetime = bm.datetime, -- creation time, not changeable
|
||||
drawer = hl.drawer, -- highlight drawer
|
||||
|
||||
Reference in New Issue
Block a user