]> Dogcows Code - chaz/openbox/commitdiff
modal transients wouldnt throw their focus up to their arent cuz the parent didnt...
authorDana Jansens <danakj@orodu.net>
Tue, 23 Jul 2002 01:05:31 +0000 (01:05 +0000)
committerDana Jansens <danakj@orodu.net>
Tue, 23 Jul 2002 01:05:31 +0000 (01:05 +0000)
src/Screen.cc
src/Window.cc

index d92973b34169fbfab457a347613cf657bedc3c0a..86d425d7be868c906705320edb3a61f365cb2982 100644 (file)
@@ -1245,12 +1245,6 @@ void BScreen::manageWindow(Window w) {
 void BScreen::unmanageWindow(BlackboxWindow *w, bool remap) {
   w->restore(remap);
 
-  if (w->getWorkspaceNumber() != BSENTINEL &&
-      w->getWindowNumber() != BSENTINEL)
-    getWorkspace(w->getWorkspaceNumber())->removeWindow(w);
-  else if (w->isIconic())
-    removeIcon(w);
-
   if (w->isNormal()) {
     // we don't list non-normal windows as managed windows
     windowList.remove(w);
@@ -1266,9 +1260,6 @@ void BScreen::unmanageWindow(BlackboxWindow *w, bool remap) {
     assert(it != end);  // the window wasnt a desktop window?
   }
 
-  if (blackbox->getFocusedWindow() == w)
-    blackbox->setFocusedWindow((BlackboxWindow *) 0);
-
   removeNetizen(w->getClientWindow());
 
   /*
index bd2f0c068862e04559943508675290599059cce9..722409f97ca7d0d1ea0fc183cc6638b53929c782 100644 (file)
@@ -361,9 +361,18 @@ BlackboxWindow::~BlackboxWindow(void) {
     if (client.transient_for != (BlackboxWindow *) ~0ul) {
       client.transient_for->client.transientList.remove(this);
     }
-    client.transient_for = (BlackboxWindow*) 0;
+    // we save our transient_for though because the workspace will use it
+    // when determining the next window to get focus
   }
 
+  if (blackbox_attrib.workspace != BSENTINEL &&
+      window_number != BSENTINEL)
+    screen->getWorkspace(blackbox_attrib.workspace)->removeWindow(this);
+  else if (flags.iconic)
+    screen->removeIcon(this);
+
+  client.transient_for = (BlackboxWindow*) 0;
+
   if (client.transientList.size() > 0) {
     // reset transient_for for all transients
     BlackboxWindowList::iterator it, end = client.transientList.end();
This page took 0.031279 seconds and 4 git commands to generate.