summaryrefslogtreecommitdiffstats
path: root/editor/plugins/canvas_item_editor_plugin.cpp
diff options
context:
space:
mode:
authorRémi Verschelde <rverschelde@gmail.com>2024-02-05 14:48:56 +0100
committerRémi Verschelde <rverschelde@gmail.com>2024-02-05 14:48:56 +0100
commite096be85c45729affd2ccc6c0ba4db7f2e63a060 (patch)
treef74a6552a11920bcd17ffe58d08ae0c368eaa934 /editor/plugins/canvas_item_editor_plugin.cpp
parentacde2a81ffc27680ac08e32f70134dfcd1dd59f0 (diff)
parent7a2c386e281db72871dda33944502b7a7e7a6df9 (diff)
downloadredot-engine-e096be85c45729affd2ccc6c0ba4db7f2e63a060.tar.gz
Merge pull request #87125 from ryevdokimov/fix-removing-preview-nodes-on-ui-cancel
Clear drag preview nodes on `NOTIFICATION_DRAG_END`
Diffstat (limited to 'editor/plugins/canvas_item_editor_plugin.cpp')
-rw-r--r--editor/plugins/canvas_item_editor_plugin.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/editor/plugins/canvas_item_editor_plugin.cpp b/editor/plugins/canvas_item_editor_plugin.cpp
index 1f9f23b5d0..5a01e4a352 100644
--- a/editor/plugins/canvas_item_editor_plugin.cpp
+++ b/editor/plugins/canvas_item_editor_plugin.cpp
@@ -6030,6 +6030,10 @@ void CanvasItemEditorViewport::_notification(int p_what) {
case NOTIFICATION_EXIT_TREE: {
disconnect("mouse_exited", callable_mp(this, &CanvasItemEditorViewport::_on_mouse_exit));
} break;
+
+ case NOTIFICATION_DRAG_END: {
+ _remove_preview();
+ } break;
}
}