]> Dogcows Code - chaz/openbox/commitdiff
better focusing. don't set the focused window when its not really set yet, and don...
authorDana Jansens <danakj@orodu.net>
Thu, 25 Jul 2002 01:24:25 +0000 (01:24 +0000)
committerDana Jansens <danakj@orodu.net>
Thu, 25 Jul 2002 01:24:25 +0000 (01:24 +0000)
src/Window.cc

index 6131ec4917b21524ac73a5c1635aa40ed70a5e3e..16715c3ee039d747e67b3707838290696db78066 100644 (file)
@@ -1582,8 +1582,6 @@ bool BlackboxWindow::setInputFocus(void) {
   if (focus_mode == F_LocallyActive || focus_mode == F_Passive) {
     XSetInputFocus(blackbox->getXDisplay(), client.window,
                    RevertToPointerRoot, CurrentTime);
-
-    blackbox->setFocusedWindow(this);
   } else {
     /* we could set the focus to none, since the window doesn't accept focus,
      * but we shouldn't set focus to nothing since this would surely make
@@ -2060,9 +2058,13 @@ void BlackboxWindow::setFocusFlag(bool focus) {
 
   if (isFocused())
     blackbox->setFocusedWindow(this);
-  
-  Clientmenu *menu = screen->getWorkspace(blackbox_attrib.workspace)->getMenu();
-  menu->setItemSelected(window_number, isFocused());
+  if (! flags.iconic) {
+    // iconic windows arent in a workspace menu!
+    Clientmenu *menu =
+      screen->getWorkspace(blackbox_attrib.workspace)->getMenu();
+    menu->setItemSelected(window_number, isFocused());
+  }
 }
 
 
This page took 0.028353 seconds and 4 git commands to generate.