]> git.sur5r.net Git - i3/i3/commitdiff
Bugfix: Don’t consider the workspace next/prev command when looking for named workspaces
authorMichael Stapelberg <michael@stapelberg.de>
Wed, 17 Aug 2011 10:28:45 +0000 (12:28 +0200)
committerMichael Stapelberg <michael@stapelberg.de>
Wed, 17 Aug 2011 10:28:45 +0000 (12:28 +0200)
Fixes #469

src/randr.c

index aa2ea351dcd8997af9b87c672d54dd2a88f29df7..6b6cd67d0e35ba524def157e7c0fa138c1f8691d 100644 (file)
@@ -425,6 +425,12 @@ void init_ws_for_output(Output *output, Con *content) {
             continue;
         DLOG("relevant command = %s\n", bind->command);
         char *target = bind->command + strlen("workspace ");
+        /* We check if this is the workspace next/prev command. Beware: The
+         * workspace names "next" and "prev" are OK, so we check before
+         * stripping the double quotes */
+        if (strncasecmp(target, "next", strlen("next")) == 0 ||
+            strncasecmp(target, "prev", strlen("prev")) == 0)
+            continue;
         if (*target == '"')
             target++;
         FREE(ws->name);