foo-wm

(Archived) Experimental Zooming IPC-based WM
git clone http://milesalan.com/git/foo-wm
Log | Files | Refs | Mirror | README | LICENSE

commit 21a4253f0b44f3b76b368adbcfc454105f9121d7
parent 5f5f66d163bc715b2a60cb9a8ccdc068eb7e35d4
Author: = <miles.sandlar@gmail.com>
Date:   Fri, 27 Jul 2012 21:16:32 -0400

Bug fix on focusing the last focus if possible

Diffstat:
Msrc/commands.c | 5++++-
1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/src/commands.c b/src/commands.c @@ -104,10 +104,13 @@ void focus(char * brotherOrPc, int delta) { while (delta != 0) { Node * newFocus; + if (brotherSwitch) { newFocus = getBrother(focusedNode, (delta < 0) ? -1 : 1); } else { - newFocus = delta < 0 ? focusedNode -> parent : focusedNode -> child; + newFocus = delta < 0 ? + focusedNode -> parent : + (focusedNode -> focus ? focusedNode -> focus : focusedNode -> child); } if (focusedNode == newFocus) return;