X-Git-Url: https://git.dogcows.com/gitweb?a=blobdiff_plain;f=otk%2Feventhandler.hh;h=f2457568d81ada4fd9e46cde254948e2fd5f320c;hb=1e58c863bbaddd2f2dbebfde740ca842e8837a1c;hp=9308ed03fb28d3668df9b0df501a0da5f48c685e;hpb=5869cc29ef15181427e65079d9a52c5d21190206;p=chaz%2Fopenbox diff --git a/otk/eventhandler.hh b/otk/eventhandler.hh index 9308ed03..f2457568 100644 --- a/otk/eventhandler.hh +++ b/otk/eventhandler.hh @@ -1,3 +1,4 @@ +// -*- mode: C++; indent-tabs-mode: nil; c-basic-offset: 2; -*- #ifndef __eventhandler__hh #define __eventhandler__hh @@ -7,11 +8,16 @@ extern "C" { #ifdef SHAPE #include #endif // SHAPE + +#ifdef XKB +#include +#endif // XKB + } namespace otk { -class OtkEventHandler { +class EventHandler { public: //! Dispatches events to one of the other handlers based on their type. virtual void handle(const XEvent &e); @@ -120,18 +126,23 @@ public: virtual void clientMessageHandler(const XClientMessageEvent &); #if defined(SHAPE) || defined(DOXYGEN_IGNORE) - //! Called when a shape extention event fires + //! Called when a shape extension event fires virtual void shapeHandler(const XShapeEvent &) {} #endif // SHAPE - virtual ~OtkEventHandler(); +#if defined(XKB) || defined(DOXYGEN_IGNORE) + //! Called when an xkb extension event fires + virtual void xkbHandler(const XkbEvent &) {} +#endif // XKB + + virtual ~EventHandler(); protected: - /*! Constructor for the OtkEventHandler class. - This is protected so that OtkEventHandlers can't be instantiated on their + /*! Constructor for the EventHandler class. + This is protected so that EventHandlers can't be instantiated on their own. */ - OtkEventHandler(); + EventHandler(); private: };