JasonWoof Got questions, comments, patches, etc.? Contact Jason Woofenden
small changes of the colors
[dwm.git] / screen.c
index b534766..255184a 100644 (file)
--- a/screen.c
+++ b/screen.c
@@ -3,6 +3,7 @@
 #include <regex.h>
 #include <stdio.h>
 #include <stdlib.h>
+#include <string.h>
 #include <X11/Xutil.h>
 
 /* static */
@@ -245,7 +246,7 @@ setlayout(const char *arg) {
        }
        else {
                for(i = 0; i < nlayouts; i++)
-                       if(arg == layouts[i].symbol)
+                       if(!strcmp(arg, layouts[i].symbol))
                                break;
                if(i == nlayouts)
                        return;
@@ -283,7 +284,7 @@ togglebar(const char *arg) {
 
 void
 togglefloating(const char *arg) {
-       if(!sel || isfloating())
+       if(!sel)
                return;
        sel->isfloating = !sel->isfloating;
        if(sel->isfloating)