]> Dogcows Code - chaz/openbox/blobdiff - openbox/action.c
move expand_tilde to ob_expand_tilde in openbox.c to make it global.
[chaz/openbox] / openbox / action.c
index c5c0e7ed4313d7808e52d6bda89664a2925ee847..7d06f12e46a29d647cadd4e8ee5eae24a3bff83e 100644 (file)
@@ -594,6 +594,11 @@ ActionString actionstrings[] =
         action_unshow_desktop,
         NULL
     },
+    {
+        "desktoplast",
+        action_desktop_last,
+        NULL
+    },
     {
         "restart",
         action_restart,
@@ -725,8 +730,11 @@ ObAction *action_parse(ObParseInst *i, xmlDocPtr doc, xmlNodePtr node)
     if (parse_attr_string("name", node, &actname)) {
         if ((act = action_from_string(actname))) {
             if (act->func == action_execute || act->func == action_restart) {
-                if ((n = parse_find_node("execute", node->xmlChildrenNode)))
-                    act->data.execute.path = parse_string(doc, n);
+                if ((n = parse_find_node("execute", node->xmlChildrenNode))) {
+                    gchar *s = parse_string(doc, n);
+                    act->data.execute.path = expand_tilde(s);
+                    g_free(s);
+                }
             } else if (act->func == action_showmenu) {
                 if ((n = parse_find_node("menu", node->xmlChildrenNode)))
                     act->data.showmenu.name = parse_string(doc, n);
@@ -1052,6 +1060,11 @@ void action_send_to_desktop_dir(union ActionData *data)
         screen_set_desktop(d);
 }
 
+void action_desktop_last(union ActionData *data)
+{
+    screen_set_desktop(screen_last_desktop);
+}
+
 void action_toggle_decorations(union ActionData *data)
 {
     ObClient *c = data->client.any.c;
This page took 0.021317 seconds and 4 git commands to generate.