From 7f0a1c1780508f236e2b80713a87c5f71ed6e600 Mon Sep 17 00:00:00 2001 From: PJB3005 Date: Tue, 26 Dec 2017 20:58:53 +0100 Subject: [PATCH] Hiding a control now fires NOTIFICATION_FOCUS_EXIT. It always removed the focus from the control, but this happened without firing the relevant notification. --- scene/main/viewport.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scene/main/viewport.cpp b/scene/main/viewport.cpp index 8f431389d84..df11a75470a 100644 --- a/scene/main/viewport.cpp +++ b/scene/main/viewport.cpp @@ -2302,7 +2302,7 @@ void Viewport::_gui_hid_control(Control *p_control) { */ if (gui.key_focus == p_control) - gui.key_focus = NULL; + _gui_remove_focus(); if (gui.mouse_over == p_control) gui.mouse_over = NULL; if (gui.tooltip == p_control)