X-Git-Url: https://git.dogcows.com/gitweb?a=blobdiff_plain;f=openbox%2Fevent.c;h=eea6583be8248053b456a2e1f165910ac457be31;hb=02c7f2e8afbfe5ebc589415a87a2ac156c9ef5af;hp=bdafd126e6acbc1f89796e908756347371e903b9;hpb=6b7737acc3f6daa4ca0d4546d2bf4cddc7236e2d;p=chaz%2Fopenbox diff --git a/openbox/event.c b/openbox/event.c index bdafd126..eea6583b 100644 --- a/openbox/event.c +++ b/openbox/event.c @@ -284,14 +284,13 @@ static gboolean event_ignore(XEvent *e, Client *client) e->xfocus.window, e->xfocus.mode, e->xfocus.detail); #endif - /* Try process a FocusIn first, and if a legit one isn't found, then - do the fallback shiznit. */ { XEvent fe; gboolean fallback = TRUE; while (TRUE) { - if (!XCheckTypedEvent(ob_display, FocusOut, &fe)) + if (!XCheckTypedWindowEvent(ob_display, FocusOut, + e->xfocus.window,&fe)) if (!XCheckTypedEvent(ob_display, FocusIn, &fe)) break; if (fe.type == FocusOut) { @@ -499,7 +498,7 @@ static void event_handle_client(Client *client, XEvent *e) #endif /* focus state can affect the stacking layer */ client_calc_layer(client); - frame_adjust_focus(client->frame); + frame_adjust_focus(client->frame, e->type == FocusIn); break; case EnterNotify: if (client_normal(client)) {