diff options
Diffstat (limited to 'editor')
25 files changed, 57 insertions, 57 deletions
diff --git a/editor/action_map_editor.cpp b/editor/action_map_editor.cpp index 3ca3576de6..dc0c62fbc9 100644 --- a/editor/action_map_editor.cpp +++ b/editor/action_map_editor.cpp @@ -847,7 +847,7 @@ void ActionMapEditor::_tree_button_pressed(Object *p_item, int p_column, int p_i int event_index = item->get_meta("__index"); Array events = action["events"]; - events.remove(event_index); + events.remove_at(event_index); action["events"] = events; emit_signal(SNAME("action_edited"), action_name, action); diff --git a/editor/connections_dialog.cpp b/editor/connections_dialog.cpp index b954c87476..d00fdd0ce7 100644 --- a/editor/connections_dialog.cpp +++ b/editor/connections_dialog.cpp @@ -240,7 +240,7 @@ void ConnectDialog::_remove_bind() { int idx = st.get_slice("/", 1).to_int() - 1; ERR_FAIL_INDEX(idx, cdbinds->params.size()); - cdbinds->params.remove(idx); + cdbinds->params.remove_at(idx); cdbinds->notify_changed(); } @@ -723,7 +723,7 @@ void ConnectionsDock::_open_connection_dialog(TreeItem &item) { c = '_'; } else { // Remove any other characters. - midname.remove(i); + midname.remove_at(i); i--; continue; } diff --git a/editor/create_dialog.cpp b/editor/create_dialog.cpp index 72aea9b630..dec4f50f03 100644 --- a/editor/create_dialog.cpp +++ b/editor/create_dialog.cpp @@ -576,7 +576,7 @@ void CreateDialog::drop_data_fw(const Point2 &p_point, const Variant &p_data, Co drop_idx--; } - favorite_list.remove(from_idx); + favorite_list.remove_at(from_idx); if (ds < 0) { favorite_list.insert(drop_idx, type); diff --git a/editor/editor_data.cpp b/editor/editor_data.cpp index aee9c21007..a163b468e6 100644 --- a/editor/editor_data.cpp +++ b/editor/editor_data.cpp @@ -70,7 +70,7 @@ void EditorHistory::cleanup_history() { } if (fail) { - history.remove(i); + history.remove_at(i); i--; } } @@ -510,7 +510,7 @@ void EditorData::remove_custom_type(const String &p_type) { for (Map<String, Vector<CustomType>>::Element *E = custom_types.front(); E; E = E->next()) { for (int i = 0; i < E->get().size(); i++) { if (E->get()[i].name == p_type) { - E->get().remove(i); + E->get().remove_at(i); if (E->get().is_empty()) { custom_types.erase(E->key()); } @@ -570,7 +570,7 @@ void EditorData::remove_scene(int p_idx) { ScriptEditor::get_singleton()->close_builtin_scripts_from_scene(edited_scene[p_idx].path); } - edited_scene.remove(p_idx); + edited_scene.remove_at(p_idx); } bool EditorData::_find_updated_instances(Node *p_root, Node *p_node, Set<String> &checked_paths) { @@ -751,7 +751,7 @@ void EditorData::move_edited_scene_to_index(int p_idx) { ERR_FAIL_INDEX(p_idx, edited_scene.size()); EditedScene es = edited_scene[current_edited_scene]; - edited_scene.remove(current_edited_scene); + edited_scene.remove_at(current_edited_scene); edited_scene.insert(p_idx, es); current_edited_scene = p_idx; } diff --git a/editor/editor_export.cpp b/editor/editor_export.cpp index e78ca7cd64..03d91ebcba 100644 --- a/editor/editor_export.cpp +++ b/editor/editor_export.cpp @@ -1534,7 +1534,7 @@ Ref<EditorExportPreset> EditorExport::get_export_preset(int p_idx) { } void EditorExport::remove_export_preset(int p_idx) { - export_presets.remove(p_idx); + export_presets.remove_at(p_idx); save_presets(); } diff --git a/editor/editor_file_dialog.cpp b/editor/editor_file_dialog.cpp index 2d7c31b64c..bea5c99c1a 100644 --- a/editor/editor_file_dialog.cpp +++ b/editor/editor_file_dialog.cpp @@ -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++; diff --git a/editor/editor_file_system.cpp b/editor/editor_file_system.cpp index d141447044..4f02a82fb5 100644 --- a/editor/editor_file_system.cpp +++ b/editor/editor_file_system.cpp @@ -577,7 +577,7 @@ bool EditorFileSystem::_update_scan_actions() { ERR_CONTINUE(idx == -1); _delete_internal_files(ia.dir->files[idx]->file); memdelete(ia.dir->files[idx]); - ia.dir->files.remove(idx); + ia.dir->files.remove_at(idx); fs_changed = true; @@ -1536,7 +1536,7 @@ void EditorFileSystem::update_file(const String &p_file) { } } memdelete(fs->files[cpos]); - fs->files.remove(cpos); + fs->files.remove_at(cpos); } call_deferred(SNAME("emit_signal"), "filesystem_changed"); //update later diff --git a/editor/editor_inspector.cpp b/editor/editor_inspector.cpp index 2729b1eb3b..e1fae47057 100644 --- a/editor/editor_inspector.cpp +++ b/editor/editor_inspector.cpp @@ -1608,11 +1608,11 @@ void EditorInspectorArray::_move_element(int p_element_index, int p_to_pos) { properties_as_array.insert(p_to_pos < 0 ? properties_as_array.size() : p_to_pos, Dictionary()); } else if (p_to_pos < 0) { // Delete the element. - properties_as_array.remove(p_element_index); + properties_as_array.remove_at(p_element_index); } else { // Move the element. properties_as_array.insert(p_to_pos, properties_as_array[p_element_index].duplicate()); - properties_as_array.remove(p_to_pos < p_element_index ? p_element_index + 1 : p_element_index); + properties_as_array.remove_at(p_to_pos < p_element_index ? p_element_index + 1 : p_element_index); } // Change the array size then set the properties. diff --git a/editor/editor_node.cpp b/editor/editor_node.cpp index 69a59b7ddb..6aaf0b063f 100644 --- a/editor/editor_node.cpp +++ b/editor/editor_node.cpp @@ -831,7 +831,7 @@ void EditorNode::_remove_plugin_from_enabled(const String &p_name) { PackedStringArray enabled_plugins = ps->get("editor_plugins/enabled"); for (int i = 0; i < enabled_plugins.size(); ++i) { if (enabled_plugins.get(i) == p_name) { - enabled_plugins.remove(i); + enabled_plugins.remove_at(i); break; } } @@ -3199,7 +3199,7 @@ void EditorNode::remove_editor_plugin(EditorPlugin *p_editor, bool p_config_chan } memdelete(singleton->main_editor_buttons[i]); - singleton->main_editor_buttons.remove(i); + singleton->main_editor_buttons.remove_at(i); break; } @@ -3758,7 +3758,7 @@ void EditorNode::_open_recent_scene(int p_idx) { ERR_FAIL_INDEX(p_idx, rc.size()); if (load_scene(rc[p_idx]) != OK) { - rc.remove(p_idx); + rc.remove_at(p_idx); EditorSettings::get_singleton()->set_project_metadata("recent_files", "scenes", rc); _update_recent_scenes(); } @@ -5177,7 +5177,7 @@ void EditorNode::remove_bottom_panel_item(Control *p_item) { bottom_panel_vb->remove_child(bottom_panel_items[i].control); bottom_panel_hb_editors->remove_child(bottom_panel_items[i].button); memdelete(bottom_panel_items[i].button); - bottom_panel_items.remove(i); + bottom_panel_items.remove_at(i); break; } } diff --git a/editor/editor_properties_array_dict.cpp b/editor/editor_properties_array_dict.cpp index a3b6f6e59b..0f59c8281f 100644 --- a/editor/editor_properties_array_dict.cpp +++ b/editor/editor_properties_array_dict.cpp @@ -413,7 +413,7 @@ void EditorPropertyArray::update_property() { void EditorPropertyArray::_remove_pressed(int p_index) { Variant array = object->get_array(); - array.call("remove", p_index); + array.call("remove_at", p_index); emit_changed(get_edited_property(), array, "", false); update_property(); diff --git a/editor/editor_run.cpp b/editor/editor_run.cpp index d7daa0c750..0a77a8b0bb 100644 --- a/editor/editor_run.cpp +++ b/editor/editor_run.cpp @@ -201,7 +201,7 @@ Error EditorRun::run(const String &p_scene, const String &p_custom_args, const L Vector<String> exec_args = p_custom_args.substr(0, placeholder_pos).split(" ", false); if (exec_args.size() >= 1) { exec = exec_args[0]; - exec_args.remove(0); + exec_args.remove_at(0); // Append the Godot executable name before we append executable arguments // (since the order is reversed when using `push_front()`). diff --git a/editor/filesystem_dock.cpp b/editor/filesystem_dock.cpp index 7ae3dcd44f..f40a048b75 100644 --- a/editor/filesystem_dock.cpp +++ b/editor/filesystem_dock.cpp @@ -197,7 +197,7 @@ Vector<String> FileSystemDock::_compute_uncollapsed_paths() { child = child->get_next(); } } - needs_check.remove(0); + needs_check.remove_at(0); } } } @@ -1093,7 +1093,7 @@ void FileSystemDock::_push_to_history() { history_pos++; if (history.size() > history_max_size) { - history.remove(0); + history.remove_at(0); history_pos = history_max_size - 1; } } @@ -1670,7 +1670,7 @@ Vector<String> FileSystemDock::_remove_self_included_paths(Vector<String> select String last_path = ""; for (int i = 0; i < selected_strings.size(); i++) { if (last_path != "" && selected_strings[i].begins_with(last_path)) { - selected_strings.remove(i); + selected_strings.remove_at(i); i--; } if (selected_strings[i].ends_with("/")) { @@ -1704,7 +1704,7 @@ void FileSystemDock::_tree_rmb_option(int p_option) { child = child->get_next(); } - needs_check.remove(0); + needs_check.remove_at(0); } } } break; @@ -2229,7 +2229,7 @@ void FileSystemDock::drop_data_fw(const Point2 &p_point, const Variant &p_data, drop_position -= offset; to_remove.sort(); for (int i = 0; i < to_remove.size(); i++) { - dirs.remove(to_remove[i] - i); + dirs.remove_at(to_remove[i] - i); } // Re-add them at the right position. diff --git a/editor/import/collada.cpp b/editor/import/collada.cpp index 19b4943e6d..c34379f1ec 100644 --- a/editor/import/collada.cpp +++ b/editor/import/collada.cpp @@ -2024,7 +2024,7 @@ void Collada::_create_skeletons(Collada::Node **p_node, NodeSkeleton *p_skeleton bool Collada::_remove_node(Node *p_parent, Node *p_node) { for (int i = 0; i < p_parent->children.size(); i++) { if (p_parent->children[i] == p_node) { - p_parent->children.remove(i); + p_parent->children.remove_at(i); return true; } if (_remove_node(p_parent->children[i], p_node)) { @@ -2038,7 +2038,7 @@ bool Collada::_remove_node(Node *p_parent, Node *p_node) { void Collada::_remove_node(VisualScene *p_vscene, Node *p_node) { for (int i = 0; i < p_vscene->root_nodes.size(); i++) { if (p_vscene->root_nodes[i] == p_node) { - p_vscene->root_nodes.remove(i); + p_vscene->root_nodes.remove_at(i); return; } if (_remove_node(p_vscene->root_nodes[i], p_node)) { @@ -2271,7 +2271,7 @@ bool Collada::_move_geometry_to_skeletons(VisualScene *p_vscene, Node *p_node, L for (int i = 0; i < p_node->children.size(); i++) { if (_move_geometry_to_skeletons(p_vscene, p_node->children[i], p_mgeom)) { - p_node->children.remove(i); + p_node->children.remove_at(i); i--; } } @@ -2325,7 +2325,7 @@ void Collada::_optimize() { for (int i = 0; i < vs.root_nodes.size(); i++) { List<Node *> mgeom; if (_move_geometry_to_skeletons(&vs, vs.root_nodes[i], &mgeom)) { - vs.root_nodes.remove(i); + vs.root_nodes.remove_at(i); i--; } diff --git a/editor/localization_editor.cpp b/editor/localization_editor.cpp index 3fe1aa557d..5c25e6aae9 100644 --- a/editor/localization_editor.cpp +++ b/editor/localization_editor.cpp @@ -98,7 +98,7 @@ void LocalizationEditor::_translation_delete(Object *p_item, int p_column, int p ERR_FAIL_INDEX(idx, translations.size()); - translations.remove(idx); + translations.remove_at(idx); undo_redo->create_action(TTR("Remove Translation")); undo_redo->add_do_property(ProjectSettings::get_singleton(), "internationalization/locale/translations", translations); @@ -276,7 +276,7 @@ void LocalizationEditor::_translation_res_option_delete(Object *p_item, int p_co ERR_FAIL_COND(!remaps.has(key)); PackedStringArray r = remaps[key]; ERR_FAIL_INDEX(idx, r.size()); - r.remove(idx); + r.remove_at(idx); remaps[key] = r; undo_redo->create_action(TTR("Remove Resource Remap Option")); @@ -321,7 +321,7 @@ void LocalizationEditor::_translation_filter_option_changed() { } } else { if (l_idx != -1) { - f_locales.remove(l_idx); + f_locales.remove_at(l_idx); } } @@ -397,7 +397,7 @@ void LocalizationEditor::_pot_delete(Object *p_item, int p_column, int p_button) ERR_FAIL_INDEX(idx, pot_translations.size()); - pot_translations.remove(idx); + pot_translations.remove_at(idx); undo_redo->create_action(TTR("Remove file from POT generation")); undo_redo->add_do_property(ProjectSettings::get_singleton(), "internationalization/locale/translations_pot_files", pot_translations); diff --git a/editor/plugins/abstract_polygon_2d_editor.cpp b/editor/plugins/abstract_polygon_2d_editor.cpp index 7cafbbc1c4..58f92a98a6 100644 --- a/editor/plugins/abstract_polygon_2d_editor.cpp +++ b/editor/plugins/abstract_polygon_2d_editor.cpp @@ -446,7 +446,7 @@ bool AbstractPolygon2DEditor::forward_gui_input(const Ref<InputEvent> &p_event) if (k->get_keycode() == Key::KEY_DELETE || k->get_keycode() == Key::BACKSPACE) { if (wip_active && selected_point.polygon == -1) { if (wip.size() > selected_point.vertex) { - wip.remove(selected_point.vertex); + wip.remove_at(selected_point.vertex); _wip_changed(); selected_point = wip.size() - 1; canvas_item_editor->update_viewport(); @@ -599,7 +599,7 @@ void AbstractPolygon2DEditor::remove_point(const Vertex &p_vertex) { Vector<Vector2> vertices = _get_polygon(p_vertex.polygon); if (vertices.size() > (_is_line() ? 2 : 3)) { - vertices.remove(p_vertex.vertex); + vertices.remove_at(p_vertex.vertex); undo_redo->create_action(TTR("Edit Polygon (Remove Point)")); _action_set_polygon(p_vertex.polygon, vertices); diff --git a/editor/plugins/animation_blend_tree_editor_plugin.cpp b/editor/plugins/animation_blend_tree_editor_plugin.cpp index 2aded41810..75d2bed1b2 100644 --- a/editor/plugins/animation_blend_tree_editor_plugin.cpp +++ b/editor/plugins/animation_blend_tree_editor_plugin.cpp @@ -58,7 +58,7 @@ void AnimationNodeBlendTreeEditor::add_custom_type(const String &p_name, const R void AnimationNodeBlendTreeEditor::remove_custom_type(const Ref<Script> &p_script) { for (int i = 0; i < add_options.size(); i++) { if (add_options[i].script == p_script) { - add_options.remove(i); + add_options.remove_at(i); return; } } diff --git a/editor/plugins/canvas_item_editor_plugin.cpp b/editor/plugins/canvas_item_editor_plugin.cpp index 1fcbb03e05..a3378d1550 100644 --- a/editor/plugins/canvas_item_editor_plugin.cpp +++ b/editor/plugins/canvas_item_editor_plugin.cpp @@ -658,7 +658,7 @@ void CanvasItemEditor::_get_canvas_items_at_pos(const Point2 &p_pos, Vector<_Sel //Remove the item if invalid if (!canvas_item || duplicate || (canvas_item != scene && canvas_item->get_owner() != scene && !scene->is_editable_instance(canvas_item->get_owner())) || (!p_allow_locked && _is_node_locked(canvas_item))) { - r_items.remove(i); + r_items.remove_at(i); i--; } else { r_items.write[i].item = canvas_item; @@ -1045,7 +1045,7 @@ bool CanvasItemEditor::_gui_input_rulers_and_guides(const Ref<InputEvent> &p_eve } } else { if (dragged_guide_index >= 0) { - vguides.remove(dragged_guide_index); + vguides.remove_at(dragged_guide_index); undo_redo->create_action(TTR("Remove Vertical Guide")); if (vguides.is_empty()) { undo_redo->add_do_method(EditorNode::get_singleton()->get_edited_scene(), "remove_meta", "_edit_vertical_guides_"); @@ -1078,7 +1078,7 @@ bool CanvasItemEditor::_gui_input_rulers_and_guides(const Ref<InputEvent> &p_eve } } else { if (dragged_guide_index >= 0) { - hguides.remove(dragged_guide_index); + hguides.remove_at(dragged_guide_index); undo_redo->create_action(TTR("Remove Horizontal Guide")); if (hguides.is_empty()) { undo_redo->add_do_method(EditorNode::get_singleton()->get_edited_scene(), "remove_meta", "_edit_horizontal_guides_"); diff --git a/editor/plugins/collision_polygon_3d_editor_plugin.cpp b/editor/plugins/collision_polygon_3d_editor_plugin.cpp index 7a8680c4dd..4c728ff757 100644 --- a/editor/plugins/collision_polygon_3d_editor_plugin.cpp +++ b/editor/plugins/collision_polygon_3d_editor_plugin.cpp @@ -285,7 +285,7 @@ EditorPlugin::AfterGUIInput CollisionPolygon3DEditor::forward_spatial_gui_input( if (closest_idx >= 0) { undo_redo->create_action(TTR("Edit Poly (Remove Point)")); undo_redo->add_undo_method(node, "set_polygon", poly); - poly.remove(closest_idx); + poly.remove_at(closest_idx); undo_redo->add_do_method(node, "set_polygon", poly); undo_redo->add_do_method(this, "_polygon_draw"); undo_redo->add_undo_method(this, "_polygon_draw"); diff --git a/editor/plugins/node_3d_editor_plugin.cpp b/editor/plugins/node_3d_editor_plugin.cpp index d6e6f0597a..d3b462cda5 100644 --- a/editor/plugins/node_3d_editor_plugin.cpp +++ b/editor/plugins/node_3d_editor_plugin.cpp @@ -1238,7 +1238,7 @@ void Node3DEditorViewport::_list_select(Ref<InputEventMouseButton> b) { Node3D *item = selection_results[i].item; if (item != scene && item->get_owner() != scene && item != scene->get_deepest_editable_node(item)) { //invalid result - selection_results.remove(i); + selection_results.remove_at(i); i--; } } diff --git a/editor/plugins/polygon_2d_editor_plugin.cpp b/editor/plugins/polygon_2d_editor_plugin.cpp index 6ffe99d4d0..79cfcbec64 100644 --- a/editor/plugins/polygon_2d_editor_plugin.cpp +++ b/editor/plugins/polygon_2d_editor_plugin.cpp @@ -584,10 +584,10 @@ void Polygon2DEditor::_uv_input(const Ref<InputEvent> &p_input) { return; } - uv_create_poly_prev.remove(closest); - uv_create_uv_prev.remove(closest); + uv_create_poly_prev.remove_at(closest); + uv_create_uv_prev.remove_at(closest); if (uv_create_colors_prev.size()) { - uv_create_colors_prev.remove(closest); + uv_create_colors_prev.remove_at(closest); } undo_redo->create_action(TTR("Remove Internal Vertex")); @@ -599,7 +599,7 @@ void Polygon2DEditor::_uv_input(const Ref<InputEvent> &p_input) { undo_redo->add_undo_method(node, "set_vertex_colors", node->get_vertex_colors()); for (int i = 0; i < node->get_bone_count(); i++) { Vector<float> bonew = node->get_bone_weights(i); - bonew.remove(closest); + bonew.remove_at(closest); undo_redo->add_do_method(node, "set_bone_weights", i, bonew); undo_redo->add_undo_method(node, "set_bone_weights", i, node->get_bone_weights(i)); } @@ -702,7 +702,7 @@ void Polygon2DEditor::_uv_input(const Ref<InputEvent> &p_input) { } if (erase_index != -1) { - polygons.remove(erase_index); + polygons.remove_at(erase_index); undo_redo->create_action(TTR("Remove Custom Polygon")); undo_redo->add_do_method(node, "set_polygons", polygons); undo_redo->add_undo_method(node, "set_polygons", node->get_polygons()); diff --git a/editor/plugins/script_editor_plugin.cpp b/editor/plugins/script_editor_plugin.cpp index 583862893c..ace8ee53e6 100644 --- a/editor/plugins/script_editor_plugin.cpp +++ b/editor/plugins/script_editor_plugin.cpp @@ -733,7 +733,7 @@ void ScriptEditor::_open_recent_script(int p_idx) { return; } - rc.remove(p_idx); + rc.remove_at(p_idx); EditorSettings::get_singleton()->set_project_metadata("recent_files", "scripts", rc); _update_recent_scripts(); _show_error_dialog(path); @@ -785,7 +785,7 @@ void ScriptEditor::_close_tab(int p_idx, bool p_save, bool p_history_back) { for (int i = 0; i < history.size(); i++) { if (history[i].control == tselected) { - history.remove(i); + history.remove_at(i); i--; history_pos--; } diff --git a/editor/plugins/tiles/tile_data_editors.cpp b/editor/plugins/tiles/tile_data_editors.cpp index d165f44334..44cf6b42bc 100644 --- a/editor/plugins/tiles/tile_data_editors.cpp +++ b/editor/plugins/tiles/tile_data_editors.cpp @@ -516,7 +516,7 @@ void GenericTilePolygonEditor::_base_control_gui_input(Ref<InputEvent> p_event) _grab_polygon_point(mb->get_position(), xform, closest_polygon, closest_point); if (closest_polygon >= 0) { PackedVector2Array old_polygon = polygons[closest_polygon]; - polygons[closest_polygon].remove(closest_point); + polygons[closest_polygon].remove_at(closest_point); undo_redo->create_action(TTR("Edit Polygons")); if (polygons[closest_polygon].size() < 3) { remove_polygon(closest_polygon); @@ -563,7 +563,7 @@ void GenericTilePolygonEditor::_base_control_gui_input(Ref<InputEvent> p_event) _grab_polygon_point(mb->get_position(), xform, closest_polygon, closest_point); if (closest_polygon >= 0) { PackedVector2Array old_polygon = polygons[closest_polygon]; - polygons[closest_polygon].remove(closest_point); + polygons[closest_polygon].remove_at(closest_point); undo_redo->create_action(TTR("Edit Polygons")); if (polygons[closest_polygon].size() < 3) { remove_polygon(closest_polygon); @@ -676,7 +676,7 @@ int GenericTilePolygonEditor::add_polygon(Vector<Point2> p_polygon, int p_index) void GenericTilePolygonEditor::remove_polygon(int p_index) { ERR_FAIL_INDEX(p_index, (int)polygons.size()); - polygons.remove(p_index); + polygons.remove_at(p_index); if (polygons.size() == 0) { button_create->set_pressed(true); diff --git a/editor/plugins/visual_shader_editor_plugin.cpp b/editor/plugins/visual_shader_editor_plugin.cpp index b1a9da9e26..da73fc093c 100644 --- a/editor/plugins/visual_shader_editor_plugin.cpp +++ b/editor/plugins/visual_shader_editor_plugin.cpp @@ -1061,7 +1061,7 @@ void VisualShaderEditor::remove_plugin(const Ref<VisualShaderNodePlugin> &p_plug void VisualShaderEditor::clear_custom_types() { for (int i = 0; i < add_options.size(); i++) { if (add_options[i].is_custom) { - add_options.remove(i); + add_options.remove_at(i); i--; } } diff --git a/editor/project_manager.cpp b/editor/project_manager.cpp index 8ee90a1184..4318f30add 100644 --- a/editor/project_manager.cpp +++ b/editor/project_manager.cpp @@ -1543,7 +1543,7 @@ void ProjectList::remove_project(int p_index, bool p_update_settings) { } memdelete(item.control); - _projects.remove(p_index); + _projects.remove_at(p_index); if (p_update_settings) { EditorSettings::get_singleton()->erase("projects/" + item.project_key); @@ -1733,7 +1733,7 @@ void ProjectList::erase_selected_projects(bool p_delete_project_contents) { } memdelete(item.control); - _projects.remove(i); + _projects.remove_at(i); --i; } } diff --git a/editor/settings_config_dialog.cpp b/editor/settings_config_dialog.cpp index 684f8aa37e..e1229729ac 100644 --- a/editor/settings_config_dialog.cpp +++ b/editor/settings_config_dialog.cpp @@ -486,7 +486,7 @@ void EditorSettingsDialog::_shortcut_button_pressed(Object *p_item, int p_column _update_shortcut_events(current_edited_identifier, Array()); } } else if (type == "event") { - current_events.remove(current_event_index); + current_events.remove_at(current_event_index); if (is_editing_action) { _update_builtin_action(current_edited_identifier, current_events); @@ -564,7 +564,7 @@ void EditorSettingsDialog::drop_data_fw(const Point2 &p_point, const Variant &p_ Array events = selected->get_parent()->get_meta("events"); Variant event_moved = events[index_moving_from]; - events.remove(index_moving_from); + events.remove_at(index_moving_from); events.insert(target_event_index, event_moved); String ident = selected->get_parent()->get_meta("shortcut_identifier"); |