diff options
author | Gilles Roudière <gilles.roudiere@gmail.com> | 2020-02-10 18:27:13 +0100 |
---|---|---|
committer | Gilles Roudière <gilles.roudiere@gmail.com> | 2020-02-10 18:27:13 +0100 |
commit | b66d45d986fd7e25f300db2bd2730987de6210fc (patch) | |
tree | 65c5ba69c7b1e1aeb1a5d587fb264c86ca5e3908 /editor/plugins | |
parent | 2dd73b1ffad10824a9f66e3ac04f4e2a7d51a85e (diff) |
Fixes a crash in the 2D editor
Diffstat (limited to 'editor/plugins')
-rw-r--r-- | editor/plugins/canvas_item_editor_plugin.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/editor/plugins/canvas_item_editor_plugin.cpp b/editor/plugins/canvas_item_editor_plugin.cpp index 1024e853be..054c7741ba 100644 --- a/editor/plugins/canvas_item_editor_plugin.cpp +++ b/editor/plugins/canvas_item_editor_plugin.cpp @@ -1989,7 +1989,7 @@ bool CanvasItemEditor::_gui_input_move(const Ref<InputEvent> &p_event) { if (selection.size() > 0) { drag_type = DRAG_MOVE; - CanvasItem *canvas_item = drag_selection[0]; + CanvasItem *canvas_item = selection[0]; Transform2D parent_xform = canvas_item->get_global_transform_with_canvas() * canvas_item->get_transform().affine_inverse(); Transform2D unscaled_transform = (transform * parent_xform * canvas_item->_edit_get_transform()).orthonormalized(); Transform2D simple_xform = viewport->get_transform() * unscaled_transform; |