Based on the patch in GNOME #575544

Index: gnome-session-2.26.0.90/data/session-properties.glade
===================================================================
--- gnome-session-2.26.0.90.orig/data/session-properties.glade	2009-04-11 15:58:23.958548837 +0200
+++ gnome-session-2.26.0.90/data/session-properties.glade	2009-04-12 10:03:06.629976211 +0200
@@ -306,7 +306,7 @@
                     <property name="visible">True</property>
                     <child>
                       <widget class="GtkButton" id="session_properties_save_button">
-                        <property name="visible">False</property>
+                        <property name="visible">True</property>
                         <property name="can_focus">True</property>
                         <property name="receives_default">True</property>
                         <child>
@@ -348,6 +348,17 @@
                     <property name="position">1</property>
                   </packing>
                 </child>
+                <child>
+                  <widget class="GtkLabel" id="session_properties_session_saved_label">
+                    <property name="visible">True</property>
+                    <property name="wrap">True</property>
+                  </widget>
+                  <packing>
+                    <property name="expand">False</property>
+                    <property name="fill">False</property>
+                    <property name="position">2</property>
+                  </packing>
+                </child>
               </widget>
               <packing>
                 <property name="position">1</property>
Index: gnome-session-2.26.0.90/gnome-session/gsm-manager.c
===================================================================
--- gnome-session-2.26.0.90.orig/gnome-session/gsm-manager.c	2009-04-11 15:56:55.566550412 +0200
+++ gnome-session-2.26.0.90/gnome-session/gsm-manager.c	2009-04-11 15:57:05.946052485 +0200
@@ -1871,6 +1871,18 @@ on_xsmp_client_logout_request (GsmXSMPCl
 }
 
 static void
+on_xsmp_client_save_request (GsmXSMPClient *client,
+			     gboolean       show_dialog,
+			     GsmManager    *manager)
+{
+	GError *error;
+
+	g_debug ("GsmManager: save_request");
+	error = NULL;
+	gsm_session_save (manager->priv->clients, &error);
+}
+
+static void
 on_store_client_added (GsmStore   *store,
                        const char *id,
                        GsmManager *manager)
@@ -1891,6 +1903,10 @@ on_store_client_added (GsmStore   *store
                                   "logout-request",
                                   G_CALLBACK (on_xsmp_client_logout_request),
                                   manager);
+		g_signal_connect (client,
+				  "save-request",
+				  G_CALLBACK (on_xsmp_client_save_request),
+				  manager);
         }
 
         g_signal_connect (client,
@@ -2841,6 +2857,27 @@ gsm_manager_shutdown (GsmManager *manage
 }
 
 gboolean
+gsm_manager_save_session (GsmManager *manager,
+			  GError	**error)
+{
+	g_debug ("GsmManager: SaveSession called");
+
+	g_return_val_if_fail (GSM_IS_MANAGER (manager), FALSE);
+
+	if (manager->priv->phase != GSM_MANAGER_PHASE_RUNNING) {
+		g_set_error (error,
+                             GSM_MANAGER_ERROR,
+                             GSM_MANAGER_ERROR_NOT_IN_RUNNING,
+                             "SaveSession interface is only available during the Running phase");
+		return FALSE;
+	}
+
+	maybe_save_session (manager);
+
+	return TRUE;
+}
+
+gboolean
 gsm_manager_can_shutdown (GsmManager *manager,
                           gboolean   *shutdown_available,
                           GError    **error)
Index: gnome-session-2.26.0.90/gnome-session/gsm-manager.h
===================================================================
--- gnome-session-2.26.0.90.orig/gnome-session/gsm-manager.h	2009-04-11 15:57:11.406052291 +0200
+++ gnome-session-2.26.0.90/gnome-session/gsm-manager.h	2009-04-11 15:57:19.160086252 +0200
@@ -152,6 +152,9 @@ gboolean            gsm_manager_is_inhib
 gboolean            gsm_manager_shutdown                       (GsmManager     *manager,
                                                                 GError        **error);
 
+gboolean            gsm_manager_save_session                   (GsmManager     *manager,
+                                                                GError        **error);
+
 gboolean            gsm_manager_can_shutdown                   (GsmManager     *manager,
                                                                 gboolean       *shutdown_available,
                                                                 GError        **error);
Index: gnome-session-2.26.0.90/gnome-session/gsm-xsmp-client.c
===================================================================
--- gnome-session-2.26.0.90.orig/gnome-session/gsm-xsmp-client.c	2009-04-11 15:57:51.498551825 +0200
+++ gnome-session-2.26.0.90/gnome-session/gsm-xsmp-client.c	2009-04-11 15:57:55.674051646 +0200
@@ -69,6 +69,7 @@ enum {
 enum {
         REGISTER_REQUEST,
         LOGOUT_REQUEST,
+	SAVE_REQUEST,
         LAST_SIGNAL
 };
 
@@ -1012,6 +1013,17 @@ gsm_xsmp_client_class_init (GsmXSMPClien
                               G_TYPE_NONE,
                               1, G_TYPE_BOOLEAN);
 
+	signals[SAVE_REQUEST] =
+		g_signal_new ("save-request",
+                              G_OBJECT_CLASS_TYPE (object_class),
+                              G_SIGNAL_RUN_LAST,
+                              G_STRUCT_OFFSET (GsmXSMPClientClass, save_request),
+                              NULL,
+                              NULL,
+                              g_cclosure_marshal_VOID__BOOLEAN,
+                              G_TYPE_NONE,
+                              1, G_TYPE_BOOLEAN);
+
         g_object_class_install_property (object_class,
                                          PROP_ICE_CONNECTION,
                                          g_param_spec_pointer ("ice-connection",
Index: gnome-session-2.26.0.90/gnome-session/gsm-xsmp-client.h
===================================================================
--- gnome-session-2.26.0.90.orig/gnome-session/gsm-xsmp-client.h	2009-04-11 15:58:08.770553085 +0200
+++ gnome-session-2.26.0.90/gnome-session/gsm-xsmp-client.h	2009-04-11 15:58:12.602052551 +0200
@@ -54,7 +54,8 @@ struct _GsmXSMPClientClass
                                           char          **client_id);
         gboolean (*logout_request)       (GsmXSMPClient  *client,
                                           gboolean        prompt);
-
+	gboolean (*save_request)	 (GsmXSMPClient  *client,
+                                          gboolean        prompt);
 
         void     (*saved_state)          (GsmXSMPClient  *client);
 
Index: gnome-session-2.26.0.90/gnome-session/org.gnome.SessionManager.xml
===================================================================
--- gnome-session-2.26.0.90.orig/gnome-session/org.gnome.SessionManager.xml	2009-04-11 15:57:31.790054168 +0200
+++ gnome-session-2.26.0.90/gnome-session/org.gnome.SessionManager.xml	2009-04-11 15:57:35.544087712 +0200
@@ -256,6 +256,14 @@
       </doc:doc>
     </method>
 
+    <method name="SaveSession">
+      <doc:doc>
+	<doc:description>
+	  <doc:para>Request to save session</doc:para>
+	</doc:description>
+      </doc:doc>
+    </method>
+
     <method name="CanShutdown">
       <arg name="is_available" direction="out" type="b">
         <doc:doc>
Index: gnome-session-2.26.0.90/capplet/gsm-properties-dialog.c
===================================================================
--- gnome-session-2.26.0.90.orig/capplet/gsm-properties-dialog.c	2009-04-11 16:04:30.250051528 +0200
+++ gnome-session-2.26.0.90/capplet/gsm-properties-dialog.c	2009-04-12 10:29:31.953978633 +0200
@@ -41,6 +41,12 @@
 #include "gsm-app-dialog.h"
 #include "eggdesktopfile.h"
 #include "gsm-util.h"
+#include <dbus/dbus-glib.h>
+#include <dbus/dbus-glib-lowlevel.h>
+
+#define GSM_SERVICE_DBUS   "org.gnome.SessionManager"
+#define GSM_PATH_DBUS	    "/org/gnome/SessionManager"
+#define GSM_INTERFACE_DBUS "org.gnome.SessionManager"
 
 #define GSM_PROPERTIES_DIALOG_GET_PRIVATE(o) (G_TYPE_INSTANCE_GET_PRIVATE ((o), GSM_TYPE_PROPERTIES_DIALOG, GsmPropertiesDialogPrivate))
 
@@ -59,6 +65,7 @@
 #define CAPPLET_DELETE_WIDGET_NAME        "session_properties_delete_button"
 #define CAPPLET_EDIT_WIDGET_NAME          "session_properties_edit_button"
 #define CAPPLET_SAVE_WIDGET_NAME          "session_properties_save_button"
+#define CAPPLET_SESSION_SAVED_WIDGET_NAME "session_properties_session_saved_label"
 #define CAPPLET_REMEMBER_WIDGET_NAME      "session_properties_remember_toggle"
 
 #define STARTUP_APP_ICON     "system-run"
@@ -1246,10 +1253,64 @@ on_autosave_value_toggled (GtkToggleButt
 }
 
 static void
+session_saved_message (GsmPropertiesDialog *dialog,
+                       const char *msg,
+                       gboolean is_error)
+{
+        GtkWidget *label;
+        gchar *markup;
+        label = glade_xml_get_widget (dialog->priv->xml, CAPPLET_SESSION_SAVED_WIDGET_NAME);
+        if (is_error)
+                markup = g_markup_printf_escaped ("<span foreground=\"red\">%s</span>", msg);
+        else
+                markup = g_markup_escape_text (msg, -1);
+        gtk_label_set_markup (GTK_LABEL (label), markup);
+        g_free (markup);
+}
+
+static void
+session_saved_cb (DBusGProxy *proxy,
+                  DBusGProxyCall *call_id,
+                  void *user_data)
+{
+        gboolean res;
+        GsmPropertiesDialog *dialog = user_data;
+
+        res = dbus_g_proxy_end_call (proxy, call_id, NULL, G_TYPE_INVALID);
+        if (res)
+                session_saved_message (dialog, _("Your session has been saved."), FALSE);
+        else
+                session_saved_message (dialog, _("Failed to save session"), TRUE);
+
+        g_object_unref (proxy);
+}
+
+static void
 on_save_session_clicked (GtkWidget           *widget,
                          GsmPropertiesDialog *dialog)
 {
-        g_debug ("Session saving is not implemented yet!");
+        DBusGConnection *conn;
+        DBusGProxy *proxy;
+        DBusGProxyCall *call;
+
+        conn = dbus_g_bus_get (DBUS_BUS_SESSION, NULL);
+        if (conn == NULL) {
+                session_saved_message (dialog, _("Could not connect to the session bus"), TRUE);
+                return;
+        }
+
+        proxy = dbus_g_proxy_new_for_name (conn, GSM_SERVICE_DBUS, GSM_PATH_DBUS, GSM_INTERFACE_DBUS);
+        if (proxy == NULL) {
+                session_saved_message (dialog, _("Could not connect to the session manager"), TRUE);
+                return;
+        }
+
+        call = dbus_g_proxy_begin_call (proxy, "SaveSession", session_saved_cb, dialog, NULL, G_TYPE_INVALID);
+        if (call == NULL) {
+                session_saved_message (dialog, _("Failed to save session"), TRUE);
+                g_object_unref (proxy);
+                return;
+        }
 }
 
 static void
Index: gnome-session-2.26.0.90/configure.in
===================================================================
--- gnome-session-2.26.0.90.orig/configure.in	2009-04-12 10:08:16.037980302 +0200
+++ gnome-session-2.26.0.90/configure.in	2009-04-12 10:08:32.332285793 +0200
@@ -67,6 +67,7 @@ PKG_CHECK_MODULES(SESSION_PROPERTIES,
         glib-2.0 >= $GLIB_REQUIRED
         gtk+-2.0 >= $GTK_REQUIRED
         libglade-2.0 >= $GLADE_REQUIRED
+        dbus-glib-1 >= $DBUS_GLIB_REQUIRED
 )
 
 PKG_CHECK_MODULES(SPLASH,
