]> Dogcows Code - chaz/openbox/commitdiff
better ordering so you can unmaximize maximized windows.. but you cant resize them
authorDana Jansens <danakj@orodu.net>
Tue, 22 May 2007 00:11:14 +0000 (00:11 +0000)
committerDana Jansens <danakj@orodu.net>
Tue, 22 May 2007 00:11:14 +0000 (00:11 +0000)
openbox/client.c

index 875c790bd8e727cc222b1796e2fef3add29718a5..1d7d17e96b343a973d856f9a00623284ae3be1b4 100644 (file)
@@ -1685,10 +1685,6 @@ void client_setup_decor_and_functions(ObClient *self)
         }
     }
 
-    /* can't resize maximized windows */
-    if (self->max_horz && self->max_vert)
-        self->functions &=~ OB_CLIENT_FUNC_RESIZE;
-
     if (!(self->functions & OB_CLIENT_FUNC_SHADE))
         self->decorations &= ~OB_FRAME_DECOR_SHADE;
     if (!(self->functions & OB_CLIENT_FUNC_ICONIFY))
@@ -1704,6 +1700,15 @@ void client_setup_decor_and_functions(ObClient *self)
         self->decorations &= ~OB_FRAME_DECOR_MAXIMIZE;
     }
 
+    if (self->max_horz && self->max_vert) {
+        /* also can't resize maximized windows.
+           do this after checking for resize to let you maximize */
+        self->functions &=~ OB_CLIENT_FUNC_RESIZE;
+
+        /* kill the handle on fully maxed windows */
+        self->decorations &= ~(OB_FRAME_DECOR_HANDLE | OB_FRAME_DECOR_GRIPS);
+    }
+
     /* If there are no decorations to remove, don't allow the user to try
        toggle the state */
     if (self->decorations == 0)
This page took 0.026796 seconds and 4 git commands to generate.