mirror of
https://github.com/koreader/koreader.git
synced 2025-08-10 00:52:38 +00:00
PDF written highlights: trash cached tiles on close (#8002)
Small followup to e3bac94d.
This commit is contained in:
@@ -889,6 +889,12 @@ function ReaderView:onPageGapUpdate(page_gap)
|
||||
end
|
||||
|
||||
function ReaderView:onSaveSettings()
|
||||
if self.document:isEdited() and G_reader_settings:readSetting("save_document") ~= "always" then
|
||||
-- Either "disable" (and the current tiles will be wrong) or "prompt" (but the
|
||||
-- prompt will happen later, too late to catch "Don't save"), so force cached
|
||||
-- tiles to be ignored on next opening.
|
||||
self.document:resetTileCacheValidity()
|
||||
end
|
||||
self.ui.doc_settings:saveSetting("tile_cache_validity_ts", self.document:getTileCacheValidity())
|
||||
self.ui.doc_settings:saveSetting("render_mode", self.render_mode)
|
||||
-- Don't etch the current rotation in stone when sticky rotation is enabled
|
||||
|
||||
Reference in New Issue
Block a user