From f7d398285764fefcc26b9b9f9086c5e6e3358c30 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Axel=20D=C3=B6rfler?= Date: Thu, 3 Dec 2009 11:56:00 +0000 Subject: [PATCH] * Always take the last window when choosing a new focus window in normal mouse mode. This fixes focus issues as describen in bug #5020. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@34456 a95241bf-73f2-0310-859d-f6bbb57e9c96 --- src/servers/app/Desktop.cpp | 12 +++--------- 1 file changed, 3 insertions(+), 9 deletions(-) diff --git a/src/servers/app/Desktop.cpp b/src/servers/app/Desktop.cpp index e67b69ed0e..66346bd8cd 100644 --- a/src/servers/app/Desktop.cpp +++ b/src/servers/app/Desktop.cpp @@ -1664,19 +1664,13 @@ Desktop::SetFocusWindow(Window* focus) } uint32 list = fCurrentWorkspace; - if (fSettings->FocusFollowsMouse()) list = kFocusList; if (focus == NULL || hasModal || hasWindowScreen) { - if (!fSettings->FocusFollowsMouse()) { - focus = FrontWindow(); - if (focus == NULL) { - // there might be no front window in case of only a single - // window with B_FLOATING_ALL_WINDOW_FEEL - focus = _CurrentWindows().LastWindow(); - } - } else + if (!fSettings->FocusFollowsMouse()) + focus = _CurrentWindows().LastWindow(); + else focus = fFocusList.LastWindow(); }