add page status to readerrolling for better page view_mode support

* now when rendering in page view mode, we only keep track of page
number instead of pos inside document. Because using pos inside
document for page view mode is really a bad idea and will lead to
many unsovlabe bugs...
This commit is contained in:
Qingping Hou
2012-12-22 13:27:46 +08:00
parent 5ab98420bd
commit 93abd2fee7
5 changed files with 122 additions and 35 deletions

View File

@@ -234,13 +234,6 @@ function Document:drawPage(target, x, y, rect, pageno, zoom, rotation, render_mo
rect.w, rect.h)
end
function Document:drawCurrentView(target, x, y, rect, pos)
self._document:gotoPos(pos)
tile_bb = Blitbuffer.new(rect.w, rect.h)
self._document:drawCurrentPage(tile_bb)
target:blitFrom(tile_bb, x, y, 0, 0, rect.w, rect.h)
end
function Document:getPageText(pageno)
-- is this worth caching? not done yet.
local page = self._document:openPage(pageno)