summaryrefslogtreecommitdiff
path: root/src/FbTk/MenuItem.cc
diff options
context:
space:
mode:
Diffstat (limited to 'src/FbTk/MenuItem.cc')
-rw-r--r--src/FbTk/MenuItem.cc5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/FbTk/MenuItem.cc b/src/FbTk/MenuItem.cc
index 7d309f4..1e708d3 100644
--- a/src/FbTk/MenuItem.cc
+++ b/src/FbTk/MenuItem.cc
@@ -30,12 +30,13 @@
30#include "App.hh" 30#include "App.hh"
31#include "StringUtil.hh" 31#include "StringUtil.hh"
32#include "Menu.hh" 32#include "Menu.hh"
33#include <X11/keysym.h>
33 34
34namespace FbTk { 35namespace FbTk {
35 36
36void MenuItem::click(int button, int time) { 37void MenuItem::click(int button, int time, unsigned int mods) {
37 if (m_command.get() != 0) { 38 if (m_command.get() != 0) {
38 if (m_menu && m_close_on_click) 39 if (m_menu && m_close_on_click && (mods & ControlMask) == 0)
39 m_menu->hide(); 40 m_menu->hide();
40 // we need a local variable, since the command may destroy this object 41 // we need a local variable, since the command may destroy this object
41 RefCount<Command> tmp(m_command); 42 RefCount<Command> tmp(m_command);