aboutsummaryrefslogtreecommitdiff
path: root/src/FbTk/EventManager.hh
diff options
context:
space:
mode:
authormarkt <markt>2007-03-04 17:47:37 (GMT)
committermarkt <markt>2007-03-04 17:47:37 (GMT)
commit4c1a242968dff12e504f281224819b7cd3850a04 (patch)
tree42a6e3de02153bc8f35cae43f89238d73e9b821a /src/FbTk/EventManager.hh
parent9477af82a5835b7336fec8879967abb67f3bd848 (diff)
downloadfluxbox_pavel-4c1a242968dff12e504f281224819b7cd3850a04.zip
fluxbox_pavel-4c1a242968dff12e504f281224819b7cd3850a04.tar.bz2
moved some code around (regarding event handling) in preparation for upcoming features
Diffstat (limited to 'src/FbTk/EventManager.hh')
-rw-r--r--src/FbTk/EventManager.hh7
1 files changed, 6 insertions, 1 deletions
diff --git a/src/FbTk/EventManager.hh b/src/FbTk/EventManager.hh
index 5bbaa00..149649b 100644
--- a/src/FbTk/EventManager.hh
+++ b/src/FbTk/EventManager.hh
@@ -43,6 +43,10 @@ public:
43 void add(EventHandler &ev, Window win) { registerEventHandler(ev, win); } 43 void add(EventHandler &ev, Window win) { registerEventHandler(ev, win); }
44 void remove(Window win) { unregisterEventHandler(win); } 44 void remove(Window win) { unregisterEventHandler(win); }
45 45
46 bool grabKeyboard(EventHandler &ev, Window win);
47 void ungrabKeyboard();
48 EventHandler *grabbingKeyboard() { return m_grabbing_keyboard; }
49
46 EventHandler *find(Window win); 50 EventHandler *find(Window win);
47 51
48 // Some events have the parent window as the xany.window 52 // Some events have the parent window as the xany.window
@@ -53,13 +57,14 @@ public:
53 void unregisterEventHandler(Window win); 57 void unregisterEventHandler(Window win);
54 58
55private: 59private:
56 EventManager() { } 60 EventManager(): m_grabbing_keyboard(0) { }
57 ~EventManager(); 61 ~EventManager();
58 void dispatch(Window win, XEvent &event, bool parent = false); 62 void dispatch(Window win, XEvent &event, bool parent = false);
59 63
60 typedef std::map<Window, EventHandler *> EventHandlerMap; 64 typedef std::map<Window, EventHandler *> EventHandlerMap;
61 EventHandlerMap m_eventhandlers; 65 EventHandlerMap m_eventhandlers;
62 EventHandlerMap m_parent; 66 EventHandlerMap m_parent;
67 EventHandler *m_grabbing_keyboard;
63}; 68};
64 69
65} //end namespace FbTk 70} //end namespace FbTk