mirror of
https://github.com/koreader/koreader.git
synced 2025-08-10 00:52:38 +00:00
[fix] Behave properly on start with shortcuts (#4772)
Regression caused by #4764. Fixes #4768.
This commit is contained in:
14
reader.lua
14
reader.lua
@@ -206,18 +206,10 @@ if ARGV[argidx] and ARGV[argidx] ~= "" then
|
||||
end)
|
||||
elseif start_with == "folder_shortcuts" then
|
||||
local FileManagerShortcuts = require("apps/filemanager/filemanagershortcuts")
|
||||
local fm_bookmark = FileManagerShortcuts:new{
|
||||
title = _("Folder shortcuts"),
|
||||
show_parent = FileManager,
|
||||
curr_path = home_dir,
|
||||
goFolder = function(folder)
|
||||
if folder ~= nil and lfs.attributes(folder, "mode") == "directory" then
|
||||
FileManager.instance.file_chooser:changeToPath(folder)
|
||||
end
|
||||
end,
|
||||
}
|
||||
UIManager:nextTick(function()
|
||||
UIManager:show(fm_bookmark)
|
||||
FileManagerShortcuts:new{
|
||||
ui = FileManager.instance,
|
||||
}:onShowFolderShortcutsDialog()
|
||||
end)
|
||||
end
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user