mirror of
https://github.com/koreader/koreader.git
synced 2025-08-10 00:52:38 +00:00
add: last reading position saving and restoring
This commit is contained in:
@@ -25,10 +25,21 @@ function CREReader:open(filename)
|
||||
return true
|
||||
end
|
||||
|
||||
function CREReader:getLastPageOrPos()
|
||||
return self.settings:readSetting("last_pos") or 0
|
||||
end
|
||||
|
||||
function CREReader:saveLastPageOrPos()
|
||||
self.settings:savesetting("last_pos", self.pos)
|
||||
end
|
||||
|
||||
function CREReader:setzoom(page, preCache)
|
||||
return
|
||||
end
|
||||
|
||||
function CREReader:addJump(pos, notes)
|
||||
end
|
||||
|
||||
function CREReader:goto(pos)
|
||||
local pos = math.min(pos, self.doc:GetFullHeight())
|
||||
pos = math.max(pos, 0)
|
||||
|
||||
Reference in New Issue
Block a user