all repos — fluxbox @ 226ec5d3715e7433fa1933e0507ae20d20f0453f

custom fork of the fluxbox windowmanager

send transient windows along with sendtoworkspace
markt markt
commit

226ec5d3715e7433fa1933e0507ae20d20f0453f

parent

f9c5bfec0762d831ad8f9bf8f7940b64792909b0

3 files changed, 33 insertions(+), 19 deletions(-)

jump to
M ChangeLogChangeLog

@@ -1,6 +1,9 @@

(Format: Year/Month/Day) Changes for 1.0.0: *07/06/03: + * Also send transient windows when sending a window to another workspace, bug + #1716900 (Mark) + Screen.cc * Only change layer to normal when removing _NET_WM_STATE_{ABOVE,BELOW} if the window is actually above/below the normal layer (thanks Jim Ramsay) Ewmh.cc
M src/Screen.ccsrc/Screen.cc

@@ -1199,31 +1199,41 @@ win = FocusControl::focusedFbWindow();

FbTk::App::instance()->sync(false); - if (win && &win->screen() == this && - (! win->isStuck())) { + if (!win || &win->screen() != this || win->isStuck()) + return; - // if iconified, deiconify it before we send it somewhere - if (win->isIconic()) - win->deiconify(); + // if iconified, deiconify it before we send it somewhere + if (win->isIconic()) + win->deiconify(); - // if the window isn't on current workspace, hide it - if (id != currentWorkspace()->workspaceID()) - win->withdraw(true); + // if the window isn't on current workspace, hide it + if (id != currentWorkspace()->workspaceID()) + win->withdraw(true); - windowMenu().hide(); + windowMenu().hide(); - reassociateWindow(win, id, true); + reassociateWindow(win, id, true); - // if the window is on current workspace, show it. - if (id == currentWorkspace()->workspaceID()) - win->deiconify(false, false); + // if the window is on current workspace, show it. + if (id == currentWorkspace()->workspaceID()) + win->deiconify(false, false); - // change workspace ? - if (changeWS && id != currentWorkspace()->workspaceID()) { - changeWorkspaceID(id); - win->setInputFocus(); + // change workspace ? + if (changeWS && id != currentWorkspace()->workspaceID()) { + changeWorkspaceID(id); + win->setInputFocus(); + } + + // send all the transients too + FluxboxWindow::ClientList::iterator client_it = win->clientList().begin(); + FluxboxWindow::ClientList::iterator client_it_end = win->clientList().end(); + for (; client_it != client_it_end; ++client_it) { + WinClient::TransientList::const_iterator it = (*client_it)->transientList().begin(); + WinClient::TransientList::const_iterator it_end = (*client_it)->transientList().end(); + for (; it != it_end; ++it) { + if ((*it)->fbwindow()) + sendToWorkspace(id, (*it)->fbwindow(), false); } - } }
M src/fluxbox.ccsrc/fluxbox.cc

@@ -916,7 +916,8 @@ if (winclient == 0 && FbTk::Menu::focused() == 0) {

#ifdef DEBUG cerr<<__FILE__<<"("<<__FUNCTION__<<") Focus out is not a FluxboxWindow !!"<<endl; #endif // DEBUG - } else if (winclient && winclient == FocusControl::focusedWindow() && + } else if (winclient && (winclient == FocusControl::focusedWindow() || + FocusControl::focusedWindow() == 0) && (winclient->fbwindow() == 0 || !winclient->fbwindow()->isMoving())) { // we don't unfocus a moving window