diff options
| author | Dana Jansens <danakj@orodu.net> | 2002-07-29 06:21:31 +0000 |
|---|---|---|
| committer | Dana Jansens <danakj@orodu.net> | 2002-07-29 06:21:31 +0000 |
| commit | 77c518f8088dfae042f96f4f6424232e6400de40 (patch) | |
| tree | 7b09e9a2d8aa0a1afca03bbf9c1c2952a7d6b44c /src/Screen.cc | |
| parent | f61a455ec1704d305d8643b8215c8e0647f4c869 (diff) | |
better sticky windows.
Diffstat (limited to 'src/Screen.cc')
| -rw-r--r-- | src/Screen.cc | 13 |
1 files changed, 11 insertions, 2 deletions
diff --git a/src/Screen.cc b/src/Screen.cc index 3cb6176b..d11894ce 100644 --- a/src/Screen.cc +++ b/src/Screen.cc @@ -1269,9 +1269,14 @@ void BScreen::unmanageWindow(BlackboxWindow *w, bool remap) { if (w->isModal()) w->setModal(False); if (w->getWorkspaceNumber() != BSENTINEL && - w->getWindowNumber() != BSENTINEL) + w->getWindowNumber() != BSENTINEL) { getWorkspace(w->getWorkspaceNumber())->removeWindow(w); - else if (w->isIconic()) + if (w->isStuck()) { + for (unsigned int i = 0; i < getNumberOfWorkspaces(); ++i) + if (i != w->getWorkspaceNumber()) + getWorkspace(i)->removeWindow(w, True); + } + } else if (w->isIconic()) removeIcon(w); if (w->isNormal()) { @@ -1515,6 +1520,10 @@ void BScreen::reassociateWindow(BlackboxWindow *w, unsigned int wkspc_id, if (w->isIconic()) { removeIcon(w); getWorkspace(wkspc_id)->addWindow(w); + if (w->isStuck()) + for (unsigned int i = 0; i < getNumberOfWorkspaces(); ++i) + if (i != w->getWorkspaceNumber()) + getWorkspace(i)->addWindow(w, True); } else if (ignore_sticky || ! w->isStuck()) { if (w->isStuck()) w->stick(); |
