[fix] filechooser: disable long-press in select mode (#8567)

reviewable/pr8575/r1
hius07 2 years ago committed by GitHub
parent 03253ef2d1
commit f83eee02dd
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -243,7 +243,6 @@ function FileManager:setupLayout()
local setHome = function(path) self:setHome(path) end
function file_chooser:onFileHold(file) -- luacheck: ignore
if file_manager.select_mode then return true end
local is_file = lfs.attributes(file, "mode") == "file"
local is_folder = lfs.attributes(file, "mode") == "directory"
local is_not_parent_folder = BaseUtil.basename(file) ~= ".."

@ -462,6 +462,7 @@ function FileChooser:onMenuSelect(item)
end
function FileChooser:onMenuHold(item)
if self.filemanager and self.filemanager.select_mode then return true end
self:onFileHold(item.path)
return true
end

Loading…
Cancel
Save