Reset ruler tool when switching tools with shortcuts

Fixes: #37056
(cherry picked from commit a99a671034)
This commit is contained in:
Dominik 'dreamsComeTrue' Jasiński 2020-03-15 10:35:53 +01:00 committed by Rémi Verschelde
parent 8ec3a33115
commit ac4cedc596
No known key found for this signature in database
GPG key ID: C3336907360768E1

View file

@ -2474,9 +2474,10 @@ bool CanvasItemEditor::_gui_input_select(const Ref<InputEvent> &p_event) {
}
bool CanvasItemEditor::_gui_input_ruler_tool(const Ref<InputEvent> &p_event) {
if (tool != TOOL_RULER)
if (tool != TOOL_RULER) {
ruler_tool_active = false;
return false;
}
Ref<InputEventMouseButton> b = p_event;
Ref<InputEventMouseMotion> m = p_event;