Reader: use existing module instances on start (#11485)

reviewable/pr11492/r1
hius07 3 months ago committed by GitHub
parent 72a6fa1e64
commit 2fca0ee989
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

@ -271,20 +271,11 @@ else
-- Always open FM modules on top of filemanager, so closing 'em doesn't result in an exit -- Always open FM modules on top of filemanager, so closing 'em doesn't result in an exit
-- because of an empty widget stack, and so they can interact with the FM instance as expected. -- because of an empty widget stack, and so they can interact with the FM instance as expected.
if start_with == "history" then if start_with == "history" then
local FileManagerHistory = require("apps/filemanager/filemanagerhistory") FileManager.instance.history:onShowHist()
FileManagerHistory:new{
ui = FileManager.instance,
}:onShowHist()
elseif start_with == "favorites" then elseif start_with == "favorites" then
local FileManagerCollection = require("apps/filemanager/filemanagercollection") FileManager.instance.collections:onShowColl()
FileManagerCollection:new{
ui = FileManager.instance,
}:onShowColl("favorites")
elseif start_with == "folder_shortcuts" then elseif start_with == "folder_shortcuts" then
local FileManagerShortcuts = require("apps/filemanager/filemanagershortcuts") FileManager.instance.folder_shortcuts:onShowFolderShortcutsDialog()
FileManagerShortcuts:new{
ui = FileManager.instance,
}:onShowFolderShortcutsDialog()
end end
exit_code = UIManager:run() exit_code = UIManager:run()
end end

Loading…
Cancel
Save