diff options
author | Rémi Verschelde <rverschelde@gmail.com> | 2019-07-25 11:09:57 +0200 |
---|---|---|
committer | Rémi Verschelde <rverschelde@gmail.com> | 2019-07-25 11:09:57 +0200 |
commit | 43238bb59af7a0b7e98540a2786d006dad8747c9 (patch) | |
tree | 67b640f9b898f0d2879b4e7eb2205dd33ebca6be /editor/editor_file_dialog.cpp | |
parent | 1481d299ea97fa1311a75a9ee39eb97d624a8619 (diff) | |
download | redot-engine-43238bb59af7a0b7e98540a2786d006dad8747c9.tar.gz |
DirAccess: Drop compat get_next(bool *is_dir) which was hidden
Fixes this warning:
```
./core/os/dir_access.h:74:17: warning: 'virtual String DirAccess::get_next(bool*)' was hidden [-Woverloaded-virtual]
```
Part of #30790.
Diffstat (limited to 'editor/editor_file_dialog.cpp')
-rw-r--r-- | editor/editor_file_dialog.cpp | 11 |
1 files changed, 4 insertions, 7 deletions
diff --git a/editor/editor_file_dialog.cpp b/editor/editor_file_dialog.cpp index 24c5a788b6..46518d387b 100644 --- a/editor/editor_file_dialog.cpp +++ b/editor/editor_file_dialog.cpp @@ -29,6 +29,7 @@ /*************************************************************************/ #include "editor_file_dialog.h" + #include "core/os/file_access.h" #include "core/os/keyboard.h" #include "core/os/os.h" @@ -731,19 +732,15 @@ void EditorFileDialog::update_file_list() { List<String> files; List<String> dirs; - bool is_dir; - bool is_hidden; String item; - while ((item = dir_access->get_next(&is_dir)) != "") { + while ((item = dir_access->get_next()) != "") { if (item == "." || item == "..") continue; - is_hidden = dir_access->current_is_hidden(); - - if (show_hidden_files || !is_hidden) { - if (!is_dir) + if (show_hidden_files || !dir_access->current_is_hidden()) { + if (!dir_access->current_is_dir()) files.push_back(item); else dirs.push_back(item); |