X-Git-Url: https://git.brokenzipper.com/gitweb?a=blobdiff_plain;f=src%2Fpython.hh;h=7c31e85c4a48ed9515dba3763be821e4ea6f85fb;hb=3682df8ed27e96067a171b71cbf58d5a00ca813b;hp=b97987817bd95869340fa55f2425cdfe26437138;hpb=28b8f67562bb7eb15134f2bf7a8394f0a009b9ba;p=chaz%2Fopenbox diff --git a/src/python.hh b/src/python.hh index b9798781..7c31e85c 100644 --- a/src/python.hh +++ b/src/python.hh @@ -53,6 +53,12 @@ enum KeyContext { NUM_KEY_CONTEXT }; +enum KeyAction { + EventKeyPress, + EventKeyRelease, + NUM_KEY_ACTION +}; + enum EventAction { EventEnterWindow, EventLeaveWindow, @@ -63,6 +69,7 @@ enum EventAction { EventShutdown, EventFocus, EventBell, + EventUrgentWindow, NUM_EVENTS }; @@ -146,16 +153,18 @@ public: Client *client; Time time; unsigned int state; - std::string key; + char *key; + KeyAction action; KeyData(int screen, Client *client, Time time, unsigned int state, - unsigned int key) { + unsigned int key, KeyAction action) { this->screen = screen; this->client = client; this->time = time; this->state = state; this->key = XKeysymToString(XKeycodeToKeysym(**otk::display, key, 0)); + this->action = action; } }; @@ -183,6 +192,9 @@ PyObject *mbind(const std::string &button, ob::MouseContext context, PyObject *kbind(PyObject *keylist, ob::KeyContext context, PyObject *func); +PyObject *kgrab(int screen, PyObject *func); +PyObject *kungrab(); + PyObject *ebind(ob::EventAction action, PyObject *func); void set_reset_key(const std::string &key);