summaryrefslogtreecommitdiffstats
path: root/scene/gui/menu_button.cpp
diff options
context:
space:
mode:
authorJuan Linietsky <reduzio@gmail.com>2020-03-19 23:32:09 -0300
committerJuan Linietsky <reduzio@gmail.com>2020-03-26 15:49:44 +0100
commitb3080bc2f4d7bc5c15b3a0ff7b67690c4677577e (patch)
tree0487e2d739133015048b1e0dd1fd9abaf7bbb18a /scene/gui/menu_button.cpp
parent09ba290364aaa5b54528e82144ec0a40e10b497b (diff)
downloadredot-engine-b3080bc2f4d7bc5c15b3a0ff7b67690c4677577e.tar.gz
Popups have also been converted to windows
Controls using the old modal API have been replaced to use popups.
Diffstat (limited to 'scene/gui/menu_button.cpp')
-rw-r--r--scene/gui/menu_button.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/scene/gui/menu_button.cpp b/scene/gui/menu_button.cpp
index 61441ff958..ba1f651b5c 100644
--- a/scene/gui/menu_button.cpp
+++ b/scene/gui/menu_button.cpp
@@ -63,6 +63,7 @@ void MenuButton::pressed() {
popup->set_size(Size2(size.width, 0));
popup->set_parent_rect(Rect2(Point2(gp - popup->get_position()), get_size()));
+ popup->take_mouse_focus();
popup->popup();
}