summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRĂ©mi Verschelde <remi@verschelde.fr>2022-03-28 00:19:01 +0200
committerGitHub <noreply@github.com>2022-03-28 00:19:01 +0200
commitbff6dc4fb9cadcbb47be74f52c8e464b415d99a6 (patch)
treef1584fcf93c94f96a025e18905d5d2e2e84c6a43
parenta5eed70fa2edcf755d6abea2077232e38381449b (diff)
parentc331a3a61437ed4e0d0a44e3072561dc66625778 (diff)
Merge pull request #59599 from YeldhamDev/node_picking_lawyer
Fix errors when locking nodes
-rw-r--r--editor/plugins/canvas_item_editor_plugin.cpp16
-rw-r--r--editor/scene_tree_editor.cpp8
2 files changed, 12 insertions, 12 deletions
diff --git a/editor/plugins/canvas_item_editor_plugin.cpp b/editor/plugins/canvas_item_editor_plugin.cpp
index d713e70251..764f467192 100644
--- a/editor/plugins/canvas_item_editor_plugin.cpp
+++ b/editor/plugins/canvas_item_editor_plugin.cpp
@@ -4324,8 +4324,8 @@ void CanvasItemEditor::_popup_callback(int p_op) {
undo_redo->add_do_method(this, "emit_signal", "item_lock_status_changed");
undo_redo->add_undo_method(this, "emit_signal", "item_lock_status_changed");
}
- undo_redo->add_do_method(viewport, "update", Variant());
- undo_redo->add_undo_method(viewport, "update", Variant());
+ undo_redo->add_do_method(viewport, "update");
+ undo_redo->add_undo_method(viewport, "update");
undo_redo->commit_action();
} break;
case UNLOCK_SELECTED: {
@@ -4346,8 +4346,8 @@ void CanvasItemEditor::_popup_callback(int p_op) {
undo_redo->add_do_method(this, "emit_signal", "item_lock_status_changed");
undo_redo->add_undo_method(this, "emit_signal", "item_lock_status_changed");
}
- undo_redo->add_do_method(viewport, "update", Variant());
- undo_redo->add_undo_method(viewport, "update", Variant());
+ undo_redo->add_do_method(viewport, "update");
+ undo_redo->add_undo_method(viewport, "update");
undo_redo->commit_action();
} break;
case GROUP_SELECTED: {
@@ -4368,8 +4368,8 @@ void CanvasItemEditor::_popup_callback(int p_op) {
undo_redo->add_do_method(this, "emit_signal", "item_group_status_changed");
undo_redo->add_undo_method(this, "emit_signal", "item_group_status_changed");
}
- undo_redo->add_do_method(viewport, "update", Variant());
- undo_redo->add_undo_method(viewport, "update", Variant());
+ undo_redo->add_do_method(viewport, "update");
+ undo_redo->add_undo_method(viewport, "update");
undo_redo->commit_action();
} break;
case UNGROUP_SELECTED: {
@@ -4390,8 +4390,8 @@ void CanvasItemEditor::_popup_callback(int p_op) {
undo_redo->add_do_method(this, "emit_signal", "item_group_status_changed");
undo_redo->add_undo_method(this, "emit_signal", "item_group_status_changed");
}
- undo_redo->add_do_method(viewport, "update", Variant());
- undo_redo->add_undo_method(viewport, "update", Variant());
+ undo_redo->add_do_method(viewport, "update");
+ undo_redo->add_undo_method(viewport, "update");
undo_redo->commit_action();
} break;
diff --git a/editor/scene_tree_editor.cpp b/editor/scene_tree_editor.cpp
index 3b8c540592..44eb5c670d 100644
--- a/editor/scene_tree_editor.cpp
+++ b/editor/scene_tree_editor.cpp
@@ -96,8 +96,8 @@ void SceneTreeEditor::_cell_button_pressed(Object *p_item, int p_column, int p_i
if (n->is_class("CanvasItem") || n->is_class("Node3D")) {
undo_redo->add_do_method(n, "remove_meta", "_edit_lock_");
undo_redo->add_undo_method(n, "set_meta", "_edit_lock_", true);
- undo_redo->add_do_method(this, "_update_tree", Variant());
- undo_redo->add_undo_method(this, "_update_tree", Variant());
+ undo_redo->add_do_method(this, "_update_tree");
+ undo_redo->add_undo_method(this, "_update_tree");
undo_redo->add_do_method(this, "emit_signal", "node_changed");
undo_redo->add_undo_method(this, "emit_signal", "node_changed");
}
@@ -114,8 +114,8 @@ void SceneTreeEditor::_cell_button_pressed(Object *p_item, int p_column, int p_i
if (n->is_class("CanvasItem") || n->is_class("Node3D")) {
undo_redo->add_do_method(n, "remove_meta", "_edit_group_");
undo_redo->add_undo_method(n, "set_meta", "_edit_group_", true);
- undo_redo->add_do_method(this, "_update_tree", Variant());
- undo_redo->add_undo_method(this, "_update_tree", Variant());
+ undo_redo->add_do_method(this, "_update_tree");
+ undo_redo->add_undo_method(this, "_update_tree");
undo_redo->add_do_method(this, "emit_signal", "node_changed");
undo_redo->add_undo_method(this, "emit_signal", "node_changed");
}