From bff3b1778be17e3cc565c0663beb3db2b374750f Mon Sep 17 00:00:00 2001 From: Julien Danjou Date: Tue, 27 May 2008 22:00:51 +0200 Subject: [PATCH] [magnifier] Use the focus stacking order Signed-off-by: Julien Danjou --- layouts/magnifier.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/layouts/magnifier.c b/layouts/magnifier.c index 46371439..c5c190cd 100644 --- a/layouts/magnifier.c +++ b/layouts/magnifier.c @@ -54,7 +54,9 @@ layout_magnifier(int screen) client_resize(focus, geometry, globalconf.resize_hints); client_raise(focus); - for(c = globalconf.clients; c; c = c->next) + for(c = client_list_prev_cycle(&globalconf.clients, focus); + c && c != focus; + c = client_list_prev_cycle(&globalconf.clients, c)) if(IS_TILED(c, screen) && c != focus) n++; @@ -67,7 +69,9 @@ layout_magnifier(int screen) geometry.height = area.height / n; geometry.width = area.width; - for(c = globalconf.clients; c; c = c->next) + for(c = client_list_prev_cycle(&globalconf.clients, focus); + c && c != focus; + c = client_list_prev_cycle(&globalconf.clients, c)) if(IS_TILED(c, screen) && c != focus) { geometry.height -= 2 * c->border;