diff options
Diffstat (limited to 'src/Screen.cc')
-rw-r--r-- | src/Screen.cc | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/src/Screen.cc b/src/Screen.cc index 47599bc..df15250 100644 --- a/src/Screen.cc +++ b/src/Screen.cc | |||
@@ -1365,11 +1365,10 @@ FluxboxWindow *BScreen::createWindow(Window client) { | |||
1365 | 1365 | ||
1366 | // always put on end of focused list, if it gets focused it'll get pushed up | 1366 | // always put on end of focused list, if it gets focused it'll get pushed up |
1367 | // there is only the one win client at this stage | 1367 | // there is only the one win client at this stage |
1368 | focusControl().addFocusBack(*winclient); | ||
1368 | if (focusControl().focusNew()) | 1369 | if (focusControl().focusNew()) |
1369 | focusControl().addFocusFront(*winclient); | 1370 | FocusControl::setFocusedWindow(winclient); |
1370 | else | 1371 | |
1371 | focusControl().addFocusBack(*winclient); | ||
1372 | |||
1373 | // we also need to check if another window expects this window to the left | 1372 | // we also need to check if another window expects this window to the left |
1374 | // and if so, then join it. | 1373 | // and if so, then join it. |
1375 | FluxboxWindow *otherwin = 0; | 1374 | FluxboxWindow *otherwin = 0; |
@@ -1407,6 +1406,9 @@ FluxboxWindow *BScreen::createWindow(WinClient &client) { | |||
1407 | return 0; | 1406 | return 0; |
1408 | } | 1407 | } |
1409 | 1408 | ||
1409 | if (focusControl().focusNew() || FocusControl::focusedWindow() == &client) | ||
1410 | FocusControl::setFocusedWindow(&client); | ||
1411 | |||
1410 | m_clientlist_sig.notify(); | 1412 | m_clientlist_sig.notify(); |
1411 | 1413 | ||
1412 | return win; | 1414 | return win; |