]> Dogcows Code - chaz/openbox/commitdiff
use focus_hilite to ensure that when a wnidow thats not focused is hilighted, the...
authorDana Jansens <danakj@orodu.net>
Wed, 8 Oct 2003 18:29:12 +0000 (18:29 +0000)
committerDana Jansens <danakj@orodu.net>
Wed, 8 Oct 2003 18:29:12 +0000 (18:29 +0000)
openbox/event.c

index 8a15d789f398bbfa606f5fd32e5fdd9cf7abc96d..11247d53ee2d93a404d72868dfe0142a23727d1b 100644 (file)
@@ -327,6 +327,15 @@ static void event_done(gpointer data)
 {
     static ObClient *last = NULL;
 
+    /* sometimes focus_hilite can be on an unfocused window, this make sure
+       it loses its focus hilite when focus moves */
+    if (focus_hilite &&
+        (focus_in && focus_hilite != focus_in) &&
+        (focus_out && focus_hilite != focus_out))
+    {
+        frame_adjust_focus(focus_hilite->frame, FALSE);
+    }
+
     if (focus_in) {
         if (focus_in != focus_client) {
             focus_set_client(focus_in);
@@ -341,6 +350,8 @@ static void event_done(gpointer data)
         client_calc_layer(focus_out);
     }
 
+    focus_hilite = focus_in;
+
     if (focus_client != last) {
         if (!focus_client)
             focus_fallback(OB_FOCUS_FALLBACK_NOFOCUS);
This page took 0.025084 seconds and 4 git commands to generate.