don't add new windows to front of focus list if they don't acquire the focus

This commit is contained in:
Mark Tiefenbruck 2007-12-25 09:14:20 -08:00
parent 35d1017959
commit 7ace5e80be
2 changed files with 2 additions and 2 deletions

View file

@ -1345,7 +1345,7 @@ FluxboxWindow *BScreen::createWindow(Window client) {
// add the window to the focus list // add the window to the focus list
// always add to front on startup to keep the focus order the same // always add to front on startup to keep the focus order the same
if (focusControl().focusNew() || Fluxbox::instance()->isStartup()) if (win->isFocused() || Fluxbox::instance()->isStartup())
focusControl().addFocusFront(*winclient); focusControl().addFocusFront(*winclient);
else else
focusControl().addFocusBack(*winclient); focusControl().addFocusBack(*winclient);

View file

@ -283,7 +283,7 @@ FluxboxWindow::FluxboxWindow(WinClient &client, FbWinFrameTheme &tm,
// add the window to the focus list // add the window to the focus list
// always add to front on startup to keep the focus order the same // always add to front on startup to keep the focus order the same
if (screen().focusControl().focusNew() || Fluxbox::instance()->isStartup()) if (m_focused || Fluxbox::instance()->isStartup())
screen().focusControl().addFocusWinFront(*this); screen().focusControl().addFocusWinFront(*this);
else else
screen().focusControl().addFocusWinBack(*this); screen().focusControl().addFocusWinBack(*this);