You've already forked godot
mirror of
https://github.com/godotengine/godot.git
synced 2025-11-06 12:20:30 +00:00
Rename remove() to remove_at() when removing by index
This commit is contained in:
committed by
Aaron Record
parent
5efe80f308
commit
e078f970db
@@ -302,7 +302,7 @@ void EditorFileDialog::_post_popup() {
|
||||
bool exists = dir_access->dir_exists(recentd[i]);
|
||||
if (!exists) {
|
||||
// Remove invalid directory from the list of Recent directories.
|
||||
recentd.remove(i--);
|
||||
recentd.remove_at(i--);
|
||||
} else {
|
||||
recent->add_item(name, folder);
|
||||
recent->set_item_metadata(recent->get_item_count() - 1, recentd[i]);
|
||||
@@ -1445,7 +1445,7 @@ void EditorFileDialog::_save_to_recent() {
|
||||
for (int i = 0; i < recent.size(); i++) {
|
||||
bool cres = recent[i].begins_with("res://");
|
||||
if (recent[i] == dir || (res == cres && count > max)) {
|
||||
recent.remove(i);
|
||||
recent.remove_at(i);
|
||||
i--;
|
||||
} else {
|
||||
count++;
|
||||
|
||||
Reference in New Issue
Block a user