wallpaper selector: quick places

This commit is contained in:
end-4
2025-08-23 23:16:18 +07:00
parent 29a149b340
commit bdc0ade117
6 changed files with 428 additions and 332 deletions
@@ -44,6 +44,7 @@ Singleton {
property string nicePath: ""
function setDirectoryIfValid(path) {
validateDirProc.nicePath = FileUtils.trimFileProtocol(path).replace(/\/+$/, "")
if (/^\/*$/.test(validateDirProc.nicePath)) validateDirProc.nicePath = "/";
validateDirProc.exec(["test", "-d", nicePath])
}
onExited: (exitCode, exitStatus) => {
@@ -61,7 +62,7 @@ Singleton {
id: files
folder: Qt.resolvedUrl(root.directory)
nameFilters: root.extensions.map(ext => `*.${ext}`)
showDirs: false
showDirs: true
showDotAndDotDot: false
showOnlyReadable: true
sortField: FolderListModel.Time