|
|
|
@ -176,36 +176,36 @@ function ReaderUI:init()
|
|
|
|
|
end
|
|
|
|
|
-- for page specific controller
|
|
|
|
|
if self.document.info.has_pages then
|
|
|
|
|
-- if needed, insert a paging container
|
|
|
|
|
table.insert(self, ReaderPaging:new{
|
|
|
|
|
-- cropping controller
|
|
|
|
|
table.insert(self, ReaderCropping:new{
|
|
|
|
|
dialog = self.dialog,
|
|
|
|
|
view = self[1],
|
|
|
|
|
ui = self
|
|
|
|
|
ui = self,
|
|
|
|
|
document = self.document,
|
|
|
|
|
})
|
|
|
|
|
-- zooming controller
|
|
|
|
|
self.zoom = ReaderZooming:new{
|
|
|
|
|
local zoom = ReaderZooming:new{
|
|
|
|
|
dialog = self.dialog,
|
|
|
|
|
view = self[1],
|
|
|
|
|
ui = self
|
|
|
|
|
}
|
|
|
|
|
table.insert(self, self.zoom) -- hold reference to zoom controller
|
|
|
|
|
-- panning controller
|
|
|
|
|
table.insert(self, ReaderPanning:new{
|
|
|
|
|
table.insert(self, zoom)
|
|
|
|
|
-- paging controller
|
|
|
|
|
table.insert(self, ReaderPaging:new{
|
|
|
|
|
dialog = self.dialog,
|
|
|
|
|
view = self[1],
|
|
|
|
|
ui = self
|
|
|
|
|
})
|
|
|
|
|
-- cropping controller
|
|
|
|
|
table.insert(self, ReaderCropping:new{
|
|
|
|
|
-- panning controller
|
|
|
|
|
table.insert(self, ReaderPanning:new{
|
|
|
|
|
dialog = self.dialog,
|
|
|
|
|
view = self[1],
|
|
|
|
|
ui = self,
|
|
|
|
|
document = self.document,
|
|
|
|
|
ui = self
|
|
|
|
|
})
|
|
|
|
|
-- hinting controller
|
|
|
|
|
table.insert(self, ReaderHinting:new{
|
|
|
|
|
dialog = self.dialog,
|
|
|
|
|
zoom = self.zoom,
|
|
|
|
|
zoom = zoom,
|
|
|
|
|
view = self[1],
|
|
|
|
|
ui = self,
|
|
|
|
|
document = self.document,
|
|
|
|
|