X-Git-Url: https://git.dogcows.com/gitweb?a=blobdiff_plain;f=plugins%2Fkeyboard%2Fkeyboard.c;h=45b93ac434d6082f21d0009a2dc546e7aa36a83a;hb=276b2be581c6cb138b439537761ff2ca42201805;hp=3fe74aea07bedca68249d5c7ac3be2993ba7a983;hpb=6357583c396382dd6ed8ac42004177f204fabe62;p=chaz%2Fopenbox diff --git a/plugins/keyboard/keyboard.c b/plugins/keyboard/keyboard.c index 3fe74aea..45b93ac4 100644 --- a/plugins/keyboard/keyboard.c +++ b/plugins/keyboard/keyboard.c @@ -78,7 +78,7 @@ void plugin_setup_config() KeyBindingTree *firstnode = NULL; static KeyBindingTree *curpos; -static guint reset_key, reset_state, button_return, button_escape; +static guint reset_key, reset_state; static Timer *chain_timer; static void grab_for_window(Window win, gboolean grab) @@ -177,9 +177,9 @@ static void event(ObEvent *e, void *foo) !(grabbed_key->state & e->data.x.e->xkey.state))) done = TRUE; else if (e->type == Event_X_KeyPress) { - if (e->data.x.e->xkey.keycode == button_return) + if (e->data.x.e->xkey.keycode == ob_keycode(OB_KEY_RETURN)) done = TRUE; - else if (e->data.x.e->xkey.keycode == button_escape) { + else if (e->data.x.e->xkey.keycode == ob_keycode(OB_KEY_ESCAPE)) { GSList *it; for (it = grabbed_key->actions; it; it = it->next) { Action *act = it->data; @@ -258,8 +258,6 @@ static void event(ObEvent *e, void *foo) void plugin_startup() { - guint i; - curpos = NULL; chain_timer = NULL; @@ -268,8 +266,6 @@ void plugin_startup() (EventHandler)event, NULL); translate_key("C-g", &reset_state, &reset_key); - translate_key("Escape", &i, &button_escape); - translate_key("Return", &i, &button_return); grab_keys(TRUE); }