foo-wm

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

commit 7c8a12fdaa0383453f560b7e80dd79ee5b6b4c9c
parent aad9d5db066c587eec1775e30b268076e1e69081
Author: = <miles.sandlar@gmail.com>
Date:   Wed, 15 Aug 2012 22:14:42 -0400

Tiny ignorant bugfix

Diffstat:
Msrc/tree.c | 6++++--
1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/src/tree.c b/src/tree.c @@ -459,8 +459,9 @@ Node * getBrotherByDirection(Node * node, int direction) { if (dest > 0) { n = node; if (!node -> next && cols != 1 && isPrime(parentChildren)) dest++; - while (dest != nodePosition) + while (dest != nodePosition) { n = n -> previous; dest++; + } return n; } break; @@ -469,8 +470,9 @@ Node * getBrotherByDirection(Node * node, int direction) { if (rows == 1) { break; } else if (dest <= parentChildren) { n = node; - while (dest != nodePosition) + while (dest != nodePosition) { n = n -> next; dest--; + } return n; } else if (dest <= parentChildren + 1 && isPrime(parentChildren)) { n = node; // Prime odd case