all repos — fluxbox @ e0d61ab4f5d43abda220ab9ee7069f897bc713c4

custom fork of the fluxbox windowmanager

use most recently focused window to attach (using screen's focus list)
(Simon)
rathnor rathnor
commit

e0d61ab4f5d43abda220ab9ee7069f897bc713c4

parent

a9c82d41d86ea632bb9acdb8591664da2cb87f6d

1 files changed, 7 insertions(+), 5 deletions(-)

jump to
M src/fluxbox.ccsrc/fluxbox.cc

@@ -22,7 +22,7 @@ // LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING

// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER // DEALINGS IN THE SOFTWARE. -// $Id: fluxbox.cc,v 1.109 2003/04/15 12:11:54 fluxgen Exp $ +// $Id: fluxbox.cc,v 1.110 2003/04/15 13:58:57 rathnor Exp $ #include "fluxbox.hh"

@@ -1190,10 +1190,12 @@ Workspace *space = screen->getCurrentWorkspace();

Workspace::Windows &wins = space->getWindowList(); if (wins.size() == 1) break; - Workspace::Windows::iterator it = wins.begin(); - for (; it != wins.end(); ++it) { - if ((*it) != focused_window) { - focused_window->attachClient((*it)->winClient()); + BScreen::FocusedWindows &fwins = screen->getFocusedList(); + BScreen::FocusedWindows::iterator it = fwins.begin(); + for (; it != fwins.end(); ++it) { + if ((*it)->fbwindow() != focused_window && + (*it)->fbwindow()->getWorkspaceNumber() == screen->getCurrentWorkspaceID()) { + focused_window->attachClient(**it); break; } }