Skip to content

Commit

Permalink
Merge pull request #46638 from Ev1lbl0w/feature-hide_gdignored_dirs
Browse files Browse the repository at this point in the history
  • Loading branch information
akien-mga authored Mar 26, 2022
2 parents cd43ab3 + 057a0e0 commit 188ca54
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion editor/editor_file_dialog.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -781,12 +781,19 @@ void EditorFileDialog::update_file_list() {
continue;
}

if (show_hidden_files || !dir_access->current_is_hidden()) {
if (show_hidden_files) {
if (!dir_access->current_is_dir()) {
files.push_back(item);
} else {
dirs.push_back(item);
}
} else if (!dir_access->current_is_hidden()) {
String full_path = cdir == "res://" ? item : dir_access->get_current_dir() + "/" + item;
if (dir_access->current_is_dir() && !EditorFileSystem::_should_skip_directory(full_path)) {
dirs.push_back(item);
} else {
files.push_back(item);
}
}
item = dir_access->get_next();
}
Expand Down

0 comments on commit 188ca54

Please sign in to comment.