You've already forked godot
mirror of
https://github.com/godotengine/godot.git
synced 2025-11-09 12:50:35 +00:00
Make ".." always appear even if dir is unlistable (likely lacking permissions), closes #1938
This commit is contained in:
@@ -339,6 +339,11 @@ void FileDialog::update_file_list() {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (dirs.find("..")==NULL) {
|
||||||
|
//may happen if lacking permissions
|
||||||
|
dirs.push_back("..");
|
||||||
|
}
|
||||||
|
|
||||||
dirs.sort_custom<NoCaseComparator>();
|
dirs.sort_custom<NoCaseComparator>();
|
||||||
files.sort_custom<NoCaseComparator>();
|
files.sort_custom<NoCaseComparator>();
|
||||||
|
|
||||||
|
|||||||
@@ -536,6 +536,11 @@ void EditorFileDialog::update_file_list() {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (dirs.find("..")==NULL) {
|
||||||
|
//may happen if lacking permissions
|
||||||
|
dirs.push_back("..");
|
||||||
|
}
|
||||||
|
|
||||||
dirs.sort_custom<NoCaseComparator>();
|
dirs.sort_custom<NoCaseComparator>();
|
||||||
files.sort_custom<NoCaseComparator>();
|
files.sort_custom<NoCaseComparator>();
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user