refactoring module registration in readerui

now every module can be looked up in readerui so that
unit test of these modules is possible.
This commit is contained in:
chrox
2014-10-09 17:41:23 +08:00
parent d01ae145b8
commit e34ad5ffe5
3 changed files with 97 additions and 94 deletions

View File

@@ -12,7 +12,9 @@ local _ = require("gettext")
local ReaderHighlight = InputContainer:new{}
function ReaderHighlight:init()
self.ui.menu:registerToMainMenu(self)
self.ui:registerPostInitCallback(function()
self.ui.menu:registerToMainMenu(self)
end)
end
function ReaderHighlight:initGesListener()