diff options
author | Juan Linietsky <reduzio@gmail.com> | 2017-09-07 11:22:07 -0300 |
---|---|---|
committer | Juan Linietsky <reduzio@gmail.com> | 2017-09-07 11:22:07 -0300 |
commit | 1eeda0f32f66b48c8df3b93f333bf702b149ba31 (patch) | |
tree | b274e9ebd9ee64edc0a412ab48d3a2ff98b54f49 /editor/plugins/canvas_item_editor_plugin.cpp | |
parent | 895140389a7306eafc9a36f51d892ece0001f223 (diff) |
Restored auto snapping of controls to pixels, fixes #10847 and probably several more issues. Made it optional in the project settings but defaults to true.
Diffstat (limited to 'editor/plugins/canvas_item_editor_plugin.cpp')
-rw-r--r-- | editor/plugins/canvas_item_editor_plugin.cpp | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/editor/plugins/canvas_item_editor_plugin.cpp b/editor/plugins/canvas_item_editor_plugin.cpp index df4598793c..3d5732c749 100644 --- a/editor/plugins/canvas_item_editor_plugin.cpp +++ b/editor/plugins/canvas_item_editor_plugin.cpp @@ -2269,6 +2269,9 @@ void CanvasItemEditor::_notification(int p_what) { if (p_what == NOTIFICATION_FIXED_PROCESS) { + + EditorNode::get_singleton()->get_scene_root()->set_snap_controls_to_pixels(GLOBAL_GET("gui/common/snap_controls_to_pixels")); + List<Node *> &selection = editor_selection->get_selected_node_list(); bool all_control = true; |