aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/FocusControl.cc7
1 files changed, 5 insertions, 2 deletions
diff --git a/src/FocusControl.cc b/src/FocusControl.cc
index 366af34..54c3d46 100644
--- a/src/FocusControl.cc
+++ b/src/FocusControl.cc
@@ -591,11 +591,14 @@ void FocusControl::setFocusedWindow(WinClient *client) {
591 BScreen *screen = client ? &client->screen() : 0; 591 BScreen *screen = client ? &client->screen() : 0;
592 if (client && screen && screen->focusControl().isCycling()) { 592 if (client && screen && screen->focusControl().isCycling()) {
593 Focusable *next = screen->focusControl().m_cycling_next; 593 Focusable *next = screen->focusControl().m_cycling_next;
594 if (next && next != client && screen->focusControl().m_cycling_list->contains(*next)) { 594 WinClient *nextClient = dynamic_cast<WinClient*>(next);
595 FluxboxWindow *nextWindow = nextClient ? 0 : dynamic_cast<FluxboxWindow*>(next);
596 if (next && nextClient != client && nextWindow != client->fbwindow() &&
597 screen->focusControl().m_cycling_list->contains(*next)) {
595 // if we're currently cycling and the client tries to juggle around focus 598 // if we're currently cycling and the client tries to juggle around focus
596 // on FocusIn events to provide client-side modality - don't let him 599 // on FocusIn events to provide client-side modality - don't let him
597 next->focus(); 600 next->focus();
598 if (WinClient *nextClient = dynamic_cast<WinClient*>(next)) 601 if (nextClient)
599 setFocusedWindow(nextClient); // doesn't happen automatically while cycling, 1148 602 setFocusedWindow(nextClient); // doesn't happen automatically while cycling, 1148
600 return; 603 return;
601 } 604 }