add goto link function for CreDocument

This commit is contained in:
chrox
2014-01-15 23:34:37 +08:00
parent f49fc5fd15
commit 1329f10fa5
2 changed files with 43 additions and 4 deletions

View File

@@ -202,6 +202,10 @@ function CreDocument:getCurrentPos()
return self._document:getCurrentPos()
end
function CreDocument:getPageLinks()
return self._document:getPageLinks()
end
function Document:gotoPos(pos)
DEBUG("CreDocument: goto position", pos)
self._document:gotoPos(pos)
@@ -212,6 +216,21 @@ function CreDocument:gotoPage(page)
self._document:gotoPage(page)
end
function CreDocument:gotoLink(link)
DEBUG("CreDocument: goto link", link)
self._document:gotoLink(link)
end
function CreDocument:goBack()
DEBUG("CreDocument: go back")
self._document:goBack()
end
function CreDocument:goForward(link)
DEBUG("CreDocument: go forward")
self._document:goForward()
end
function CreDocument:getCurrentPage()
return self._document:getCurrentPage()
end