X-Git-Url: https://git.brokenzipper.com/gitweb?a=blobdiff_plain;f=src%2Fpython.hh;h=7c31e85c4a48ed9515dba3763be821e4ea6f85fb;hb=3682df8ed27e96067a171b71cbf58d5a00ca813b;hp=c346f928f89bc8d87772a16c17d98bac9853403e;hpb=ef02a0c8ae65f169157c90064a335303e964a4c1;p=chaz%2Fopenbox diff --git a/src/python.hh b/src/python.hh index c346f928..7c31e85c 100644 --- a/src/python.hh +++ b/src/python.hh @@ -32,7 +32,7 @@ enum MouseContext { MC_MaximizeButton, MC_CloseButton, MC_IconifyButton, - MC_StickyButton, + MC_AllDesktopsButton, MC_Grip, MC_Root, MC_MenuItem, @@ -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::display, + this->key = XKeysymToString(XKeycodeToKeysym(**otk::display, key, 0)); + this->action = action; } }; @@ -183,11 +192,14 @@ 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); -PyObject *send_client_msg(Window target, int type, Window about, +PyObject *send_client_msg(Window target, Atom type, Window about, long data, long data1 = 0, long data2 = 0, long data3 = 0, long data4 = 0); }