]> git.mdlowis.com Git - proto/lwm.git/commitdiff
removed gravity handling
authorMichael D. Lowis <mike.lowis@gentex.com>
Mon, 9 Mar 2020 20:38:59 +0000 (16:38 -0400)
committerMichael D. Lowis <mike.lowis@gentex.com>
Mon, 9 Mar 2020 20:38:59 +0000 (16:38 -0400)
manage.c

index a40764dce95f7b571fad07d019bf39089f6d8dd9..eb0caba46072f039fa5503d73a9b6555f27e1c1d 100644 (file)
--- a/manage.c
+++ b/manage.c
@@ -154,13 +154,6 @@ manage(Client * c, int mapped)
             /* Use the specified window position. */
             c->size.x = x;
             c->size.y = y;
-
-            /*
-             * We need to be careful of the right-hand edge and
-             * bottom. We can use the window gravity (if specified)
-             * to handle this. (See section 4.1.2.3 of the ICCCM.)
-             */
-            applyGravity(c);
         }
     }
 
@@ -219,25 +212,6 @@ manage(Client * c, int mapped)
     Client_SetState(c, NormalState);
 }
 
-static void
-applyGravity(Client *c) {
-    if (c->framed == False) return; /* only required for framed windows*/
-    if (c->size.flags & PWinGravity) {
-        switch (c->size.win_gravity) {
-            case NorthEastGravity:
-                c->size.x -= 2 * border;
-                break;
-            case SouthWestGravity:
-                c->size.y -= 2 * border;
-                break;
-            case SouthEastGravity:
-                c->size.x -= 2 * border;
-                c->size.y -= 2 * border;
-                break;
-        }
-    }
-}
-
 static int
 getProperty(Window w, Atom a, Atom type, long len, unsigned char **p) {
     Atom    real_type;