X-Git-Url: https://git.dogcows.com/gitweb?a=blobdiff_plain;f=openbox%2Faction.c;h=a01f4d061724b5e5bac25ea156438fff2393bef8;hb=a71a98b667c298fef7895f4d9a07eccb06cc6090;hp=39da39a5b7842ec4159545abd1f3ddf9ad7f7ef5;hpb=5e9e266722826fbd5907df1bf900864ab23f6539;p=chaz%2Fopenbox diff --git a/openbox/action.c b/openbox/action.c index 39da39a5..a01f4d06 100644 --- a/openbox/action.c +++ b/openbox/action.c @@ -57,7 +57,7 @@ static void client_action_end(union ActionData *data) event will come as a GrabNotify which is ignored, so this makes a fake enter event */ - if ((c = client_under_pointer())) + if ((c = client_under_pointer()) && c != data->any.c) event_enter_client(c); } } @@ -1151,13 +1151,9 @@ void action_run_list(GSList *acts, ObClient *c, ObFrameContext context, { /* interactive actions are not queued */ a->func(&a->data); - } else if (c && - (context == OB_FRAME_CONTEXT_CLIENT || - (c->type == OB_CLIENT_TYPE_DESKTOP && - context == OB_FRAME_CONTEXT_DESKTOP)) && - (a->func == action_focus || - a->func == action_activate || - a->func == action_showmenu)) + } else if (a->func == action_focus || + a->func == action_activate || + a->func == action_showmenu) { /* XXX MORE UGLY HACK actions from clicks on client windows are NOT queued. @@ -1177,11 +1173,15 @@ void action_run_list(GSList *acts, ObClient *c, ObFrameContext context, pointer. ugh. also with the menus, there is a race going on. if the - desktop wants to pop up a menu, and we do to, we send them + desktop wants to pop up a menu, and we do too, we send them the button before we pop up the menu, so they pop up their menu first. but not always. if we pop up our menu before sending them the button press, then the result is deterministic. yay. + + XXX further more. focus actions are not queued at all, + because if you bind focus->showmenu, the menu will get + hidden to do the focusing */ a->func(&a->data); } else @@ -1311,7 +1311,7 @@ void action_focus(union ActionData *data) void action_unfocus (union ActionData *data) { if (data->client.any.c == focus_client) - focus_fallback(FALSE); + focus_fallback(FALSE, FALSE); } void action_iconify(union ActionData *data)