diff options
Diffstat (limited to 'src/FocusControl.cc')
-rw-r--r-- | src/FocusControl.cc | 10 |
1 files changed, 2 insertions, 8 deletions
diff --git a/src/FocusControl.cc b/src/FocusControl.cc index e0bb886..c5441dd 100644 --- a/src/FocusControl.cc +++ b/src/FocusControl.cc | |||
@@ -50,9 +50,6 @@ FocusControl::FocusControl(BScreen &screen): | |||
50 | CLICKTABFOCUS, | 50 | CLICKTABFOCUS, |
51 | screen.name()+".tabFocusModel", | 51 | screen.name()+".tabFocusModel", |
52 | screen.altName()+".TabFocusModel"), | 52 | screen.altName()+".TabFocusModel"), |
53 | m_focus_last(screen.resourceManager(), true, | ||
54 | screen.name()+".focusLastWindow", | ||
55 | screen.altName()+".FocusLastWindow"), | ||
56 | m_focus_new(screen.resourceManager(), true, | 53 | m_focus_new(screen.resourceManager(), true, |
57 | screen.name()+".focusNewWindows", | 54 | screen.name()+".focusNewWindows", |
58 | screen.altName()+".FocusNewWindows"), | 55 | screen.altName()+".FocusNewWindows"), |
@@ -398,15 +395,12 @@ void FocusControl::revertFocus(BScreen &screen) { | |||
398 | 395 | ||
399 | if (screen.focusControl().isCycling()) | 396 | if (screen.focusControl().isCycling()) |
400 | return; | 397 | return; |
401 | // Relevant resources: | 398 | |
402 | // resource.focus_last = whether we focus last focused when changing workspace | ||
403 | // BScreen::FocusModel = sloppy, click, whatever | ||
404 | WinClient *next_focus = | 399 | WinClient *next_focus = |
405 | screen.focusControl().lastFocusedWindow(screen.currentWorkspaceID()); | 400 | screen.focusControl().lastFocusedWindow(screen.currentWorkspaceID()); |
406 | 401 | ||
407 | // if setting focus fails, or isn't possible, fallback correctly | 402 | // if setting focus fails, or isn't possible, fallback correctly |
408 | if (!(next_focus && next_focus->fbwindow() && | 403 | if (!(next_focus && next_focus->focus())) { |
409 | next_focus->fbwindow()->setCurrentClient(*next_focus, true))) { | ||
410 | setFocusedWindow(0); // so we don't get dangling m_focused_window pointer | 404 | setFocusedWindow(0); // so we don't get dangling m_focused_window pointer |
411 | switch (screen.focusControl().focusModel()) { | 405 | switch (screen.focusControl().focusModel()) { |
412 | case FocusControl::MOUSEFOCUS: | 406 | case FocusControl::MOUSEFOCUS: |