X-Git-Url: https://git.dogcows.com/gitweb?a=blobdiff_plain;f=src%2Fbindings.hh;h=8e91b5b681323acb63fe4b48c39f2aca0d44a400;hb=1f8b8425ae82c2c086f6648b7608b37685997634;hp=b3078d85a000b9ea0b582c59e35e9bbee0ac00b3;hpb=660ad41ca0b1c48525bba071a27def141ad1cbfe;p=chaz%2Fopenbox diff --git a/src/bindings.hh b/src/bindings.hh index b3078d85..8e91b5b6 100644 --- a/src/bindings.hh +++ b/src/bindings.hh @@ -82,6 +82,11 @@ private: typedef std::list ButtonBindingList; ButtonBindingList _buttons[NUM_MOUSE_CONTEXT]; + void grabButton(bool grab, const Binding &b, MouseContext context, + OBClient *client); + + PyObject *_events[NUM_EVENTS]; + public: //! Initializes an OBBindings object OBBindings(); @@ -124,6 +129,17 @@ public: void removeAllButtons(); void fireButton(ButtonData *data); + + //! Bind a callback for an event + bool addEvent(EventAction action, PyObject *callback); + + //! Unbind the callback function from an event + bool removeEvent(EventAction action); + + //! Remove all callback functions + void removeAllEvents(); + + void fireEvent(EventData *data); }; }