aboutsummaryrefslogtreecommitdiff
path: root/src/FbTk
diff options
context:
space:
mode:
authormarkt <markt>2007-12-13 18:42:05 (GMT)
committermarkt <markt>2007-12-13 18:42:05 (GMT)
commitb001ea9f1feb32a878b95a0b78c3fb0240f6df68 (patch)
treeb9440acc1d1b44302f21eefb1fbda30096a50499 /src/FbTk
parent8b7464046cea5e521ac46811591b0fce0c45aca1 (diff)
downloadfluxbox_paul-b001ea9f1feb32a878b95a0b78c3fb0240f6df68.zip
fluxbox_paul-b001ea9f1feb32a878b95a0b78c3fb0240f6df68.tar.bz2
close menus when they lose focus, instead of on [exec] commands
Diffstat (limited to 'src/FbTk')
-rw-r--r--src/FbTk/Menu.cc2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/FbTk/Menu.cc b/src/FbTk/Menu.cc
index 4c41161..88240f1 100644
--- a/src/FbTk/Menu.cc
+++ b/src/FbTk/Menu.cc
@@ -815,6 +815,8 @@ void Menu::handleEvent(XEvent &event) {
815 if (event.type == FocusOut) { 815 if (event.type == FocusOut) {
816 if (s_focused == this) 816 if (s_focused == this)
817 s_focused = 0; 817 s_focused = 0;
818 if (shown == this && !m_torn)
819 hide();
818 // I don't know why, but I get a FocusIn event when closing the menu with 820 // I don't know why, but I get a FocusIn event when closing the menu with
819 // the mouse over it -- probably an xorg bug, but it's easy to address here 821 // the mouse over it -- probably an xorg bug, but it's easy to address here
820 } else if (event.type == FocusIn && m_visible) { 822 } else if (event.type == FocusIn && m_visible) {