]> Dogcows Code - chaz/openbox/blobdiff - openbox/actions/resizerelative.c
ANSI function declarations, ie () -> (void)
[chaz/openbox] / openbox / actions / resizerelative.c
index 1aefb515d8363040321305c83acf3409beb67f20..f705c292bf8b75d4f30607cf6bf9875378e73ba0 100644 (file)
@@ -15,7 +15,7 @@ static gpointer setup_func(ObParseInst *i, xmlDocPtr doc, xmlNodePtr node);
 static void     free_func(gpointer options);
 static gboolean run_func(ObActionsData *data, gpointer options);
 
-void action_resizerelative_startup()
+void action_resizerelative_startup(void)
 {
     actions_register("ResizeRelative",
                      setup_func,
@@ -35,9 +35,11 @@ static gpointer setup_func(ObParseInst *i, xmlDocPtr doc, xmlNodePtr node)
         o->left = parse_int(doc, n);
     if ((n = parse_find_node("right", node)))
         o->right = parse_int(doc, n);
-    if ((n = parse_find_node("top", node)))
+    if ((n = parse_find_node("top", node)) ||
+        (n = parse_find_node("up", node)))
         o->top = parse_int(doc, n);
-    if ((n = parse_find_node("bottom", node)))
+    if ((n = parse_find_node("bottom", node)) ||
+        (n = parse_find_node("down", node)))
         o->bottom = parse_int(doc, n);
 
     return o;
@@ -76,9 +78,9 @@ static gboolean run_func(ObActionsData *data, gpointer options)
         yoff = yoff == 0 ? 0 :
             (yoff < 0 ? MAX(yoff, oh-nh) : MIN(yoff, oh-nh));
 
-        actions_client_move(data, FALSE);
-        client_move_resize(c, x + xoff, y + yoff, nw, nh);
         actions_client_move(data, TRUE);
+        client_move_resize(c, x + xoff, y + yoff, nw, nh);
+        actions_client_move(data, FALSE);
     }
 
     return FALSE;
This page took 0.02054 seconds and 4 git commands to generate.