diff options
author | PouleyKetchoupp <pouleyketchoup@gmail.com> | 2021-07-21 12:03:03 -0700 |
---|---|---|
committer | PouleyKetchoupp <pouleyketchoup@gmail.com> | 2021-07-21 12:03:03 -0700 |
commit | 0b4037fe642911a375fc0466c901dce68e4b6856 (patch) | |
tree | 3cfb5a2426d7d7ec794db701dcc0e8c0d4b8987a /scene/gui | |
parent | e248d2629ab9cb1dcfa91af5202af4f17754e44f (diff) |
Fix logic for Popup closing when parent is focused
The member popped_up is used to avoid closing a Popup before it had a
chance to be focused. It wasn't reset properly when the popup is hidden,
causing the Popup to close right after showing in some random cases
(spotted on X11, might not happen on Windows).
Diffstat (limited to 'scene/gui')
-rw-r--r-- | scene/gui/popup.cpp | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/scene/gui/popup.cpp b/scene/gui/popup.cpp index 5e1c8cec37..f7e7e1cd60 100644 --- a/scene/gui/popup.cpp +++ b/scene/gui/popup.cpp @@ -72,6 +72,7 @@ void Popup::_notification(int p_what) { } else { _deinitialize_visible_parents(); emit_signal(SNAME("popup_hide")); + popped_up = false; } } break; |