From 1c7a33c64c2a2a556fd8b27b201274e8b3a5fb01 Mon Sep 17 00:00:00 2001 From: fluxgen Date: Wed, 10 Jul 2002 14:51:32 +0000 Subject: minor indentation and comments --- src/Screen.cc | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/src/Screen.cc b/src/Screen.cc index 3cc0648..fb03d5a 100644 --- a/src/Screen.cc +++ b/src/Screen.cc @@ -22,7 +22,7 @@ // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER // DEALINGS IN THE SOFTWARE. -// $Id: Screen.cc,v 1.54 2002/06/02 22:48:38 fluxgen Exp $ +// $Id: Screen.cc,v 1.55 2002/07/10 14:51:32 fluxgen Exp $ //use GNU extensions #ifndef _GNU_SOURCE @@ -1119,8 +1119,8 @@ void BScreen::nextFocus(int opts) { const int num_windows = getCurrentWorkspace()->getCount(); if ((focused = fluxbox->getFocusedWindow())) { - if (focused->getScreen()->getScreenNumber() == - getScreenNumber()) { + if (focused->getScreen()->getScreenNumber() == + getScreenNumber()) { have_focused = true; focused_window_number = focused->getWindowNumber(); } @@ -1130,7 +1130,8 @@ void BScreen::nextFocus(int opts) { Workspace *wksp = getCurrentWorkspace(); Workspace::Windows wins = wksp->getWindowList(); Workspace::Windows::iterator it = wins.begin(); - for (; *it != focused; ++it); + for (; *it != focused; ++it); //get focused window iterator + do { ++it; if (it == wins.end()) @@ -1142,6 +1143,7 @@ void BScreen::nextFocus(int opts) { if (*it != focused) wksp->raiseWindow(*it); + } else if (num_windows >= 1) { FluxboxWindow *next = current_workspace->getWindow(0); //don't raise next window if input focus fails -- cgit v0.11.2