summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorDana Jansens <danakj@orodu.net>2002-08-14 06:15:08 +0000
committerDana Jansens <danakj@orodu.net>2002-08-14 06:15:08 +0000
commit4bebd476c30492f26421392a4d6dd0a20289aaa7 (patch)
tree801c804ac5e6837f38155a07a82e4ce47e8d35db /src
parent75b6a5a378966efc09c355109ab42467ddc6d845 (diff)
remove the net_wm_desktop/state hints from a window when we stop managing it, so that if an app reuses the window, we don't place it on the wrong workspace the second time.
Diffstat (limited to 'src')
-rw-r--r--src/Window.cc12
1 files changed, 9 insertions, 3 deletions
diff --git a/src/Window.cc b/src/Window.cc
index 60182ce9..dd5f3b71 100644
--- a/src/Window.cc
+++ b/src/Window.cc
@@ -2701,7 +2701,7 @@ void BlackboxWindow::propertyNotifyEvent(const XPropertyEvent *pe) {
if (pe->state == PropertyDelete)
return;
-#ifdef DEBUG
+#if 0
fprintf(stderr, "BlackboxWindow::propertyNotifyEvent(): for 0x%lx\n",
client.window);
#endif
@@ -2802,7 +2802,7 @@ void BlackboxWindow::propertyNotifyEvent(const XPropertyEvent *pe) {
void BlackboxWindow::exposeEvent(const XExposeEvent *ee) {
-#ifdef DEBUG
+#if 0
fprintf(stderr, "BlackboxWindow::exposeEvent() for 0x%lx\n", client.window);
#endif
@@ -3611,7 +3611,7 @@ void BlackboxWindow::endResize(void) {
void BlackboxWindow::motionNotifyEvent(const XMotionEvent *me) {
-#ifdef DEBUG
+#if 0
fprintf(stderr, "BlackboxWindow::motionNotifyEvent() for 0x%lx\n",
client.window);
#endif
@@ -3730,6 +3730,12 @@ void BlackboxWindow::restore(bool remap) {
if (flags.shaded && ! flags.iconic)
setState(NormalState);
+ // erase the netwm stuff that we read when a window maps, so that it
+ // doesn't persist between mappings.
+ // (these are the ones read in getNetWMFlags().)
+ xatom->eraseValue(client.window, XAtom::net_wm_desktop);
+ xatom->eraseValue(client.window, XAtom::net_wm_state);
+
restoreGravity(client.rect);
XUnmapWindow(blackbox->getXDisplay(), frame.window);