Skip to content

Commit

Permalink
Merge pull request #36082 from groud/fix_crash_2D_editor
Browse files Browse the repository at this point in the history
Fixes a crash in the 2D editor
  • Loading branch information
akien-mga authored Feb 10, 2020
2 parents 2dd73b1 + b66d45d commit 5061356
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion editor/plugins/canvas_item_editor_plugin.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -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;
Expand Down

0 comments on commit 5061356

Please sign in to comment.