about summary refs log tree commit diff stats
diff options
context:
space:
mode:
-rw-r--r--view.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/view.c b/view.c
index 2143d70..b4de573 100644
--- a/view.c
+++ b/view.c
@@ -302,10 +302,11 @@ zoom(Arg *arg) {
 	}
 	for(n = 0, c = nexttiled(clients); c; c = nexttiled(c->next))
 		n++;
-	if(n <= nmaster || (arrange == dofloat))
-		return;
 
-	if(ismaster((c = sel))) {
+	c = sel;
+	if(n <= nmaster || (arrange == dofloat))
+		pop(c);
+	else if(ismaster(sel)) {
 		if(!(c = topofstack()))
 			return;
 		swap(c, sel);
f='#n105'>105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134