Merge branch 'backport' into work
[mikachu/openbox.git] / openbox / actions / desktop.c
index b50534d..d5535f6 100644 (file)
@@ -86,7 +86,7 @@ static gpointer setup_go_func(xmlNodePtr node)
         }
         else {
             o->type = ABSOLUTE;
-            o->abs.desktop = obt_parse_node_int(n) - 1;
+            o->abs.desktop = atoi(s) - 1;
         }
         g_free(s);
     }
@@ -136,12 +136,14 @@ static gboolean run_func(ObActionsData *data, gpointer options)
     if (d < screen_num_desktops && d != screen_desktop) {
         gboolean go = TRUE;
 
+        actions_client_move(data, TRUE);
         if (o->send && data->client && client_normal(data->client)) {
             client_set_desktop(data->client, d, o->follow, FALSE);
             go = o->follow;
         }
 
         if (go) screen_set_desktop(d, TRUE);
+        actions_client_move(data, FALSE);
     }
     return FALSE;
 }