]> git.sur5r.net Git - i3/i3/blobdiff - src/commands.c
Merge pull request #3390 from orestisf1993/resize-tile
[i3/i3] / src / commands.c
index 33743848dc4d5f67e14228553d6c41c9194b86fd..387c7cfa732848e4f0a54275794295357bdaa8ec 100644 (file)
@@ -694,13 +694,15 @@ void cmd_resize_set(I3_CMD, long cwidth, const char *mode_width, long cheight, c
                 continue;
             }
 
-            if (cwidth > 0 && mode_width) {
+            if (cwidth > 0) {
+                bool is_ppt = mode_width && strcmp(mode_width, "ppt") == 0;
                 success &= resize_set_tiling(current_match, cmd_output, current->con,
-                                             HORIZ, strcmp(mode_width, "ppt") == 0, cwidth);
+                                             HORIZ, is_ppt, cwidth);
             }
-            if (cheight > 0 && mode_height) {
+            if (cheight > 0) {
+                bool is_ppt = mode_height && strcmp(mode_height, "ppt") == 0;
                 success &= resize_set_tiling(current_match, cmd_output, current->con,
-                                             VERT, strcmp(mode_height, "ppt") == 0, cheight);
+                                             VERT, is_ppt, cheight);
             }
         }
     }