[Xfce4-commits] <xfce4-session:master> Port the panel plugin to libxfce4ui.
Nick Schermer
noreply at xfce.org
Thu Jan 28 19:52:02 CET 2010
Updating branch refs/heads/master
to 3cd8a45a9d6c9ae25f46883835ab549ffe790751 (commit)
from 504890be4d2ec737ec8ed013852b2a04a1fbc063 (commit)
commit 3cd8a45a9d6c9ae25f46883835ab549ffe790751
Author: Jérôme Guelfucci <jeromeg at xfce.org>
Date: Wed Jan 20 08:32:25 2010 +0100
Port the panel plugin to libxfce4ui.
panel-plugin/Makefile.am | 4 ++--
panel-plugin/xfsm-logout-plugin.c | 19 +++++++++++--------
2 files changed, 13 insertions(+), 10 deletions(-)
diff --git a/panel-plugin/Makefile.am b/panel-plugin/Makefile.am
index 7b390ad..bd04430 100644
--- a/panel-plugin/Makefile.am
+++ b/panel-plugin/Makefile.am
@@ -6,7 +6,7 @@ plugin_cflags = \
$(LIBX11_CFLAGS) \
$(LIBXFCE4PANEL_CFLAGS) \
$(LIBXFCE4UTIL_CFLAGS) \
- $(LIBXFCEGUI4_CFLAGS) \
+ $(LIBXFCE4UI_CFLAGS) \
$(GTK_CFLAGS) \
$(DBUS_GLIB_CFLAGS) \
-DLOCALEDIR=\"$(localedir)\"
@@ -15,7 +15,7 @@ plugin_libs = \
$(LIBX11_LIBS) \
$(LIBXFCE4PANEL_LIBS) \
$(LIBXFCE4UTIL_LIBS) \
- $(LIBXFCEGUI4_LIBS) \
+ $(LIBXFCE4UI_LIBS) \
$(GTK_LIBS) \
$(DBUS_GLIB_LIBS)
diff --git a/panel-plugin/xfsm-logout-plugin.c b/panel-plugin/xfsm-logout-plugin.c
index 316cf3a..d839acb 100644
--- a/panel-plugin/xfsm-logout-plugin.c
+++ b/panel-plugin/xfsm-logout-plugin.c
@@ -42,7 +42,7 @@
#include <gtk/gtk.h>
#include <libxfce4util/libxfce4util.h>
-#include <libxfcegui4/libxfcegui4.h>
+#include <libxfce4ui/libxfce4ui.h>
#include <libxfce4panel/libxfce4panel.h>
#include "xfsm-logout-plugin-ui.h"
@@ -142,7 +142,13 @@ static void
xfsm_logout_plugin_lock_screen(GtkAction *action,
gpointer user_data)
{
- xfce_exec("xflock4", FALSE, FALSE, NULL);
+ GError *error = NULL;
+
+ if (!g_spawn_command_line_async("xflock4", error)) {
+ xfce_dialog_show_error (NULL,
+ error,
+ _("Xfclock4 could not be launched"));
+ }
}
static gboolean
@@ -301,12 +307,9 @@ xfsm_logout_plugin_show_confirmation_dialog(XfsmLogoutPlugin *logout_plugin,
GError *error = NULL;
if(!xfsm_logout_plugin_do_dbus_call(logout_plugin, type, &error)) {
- xfce_message_dialog(NULL, _("Session Error"),
- GTK_STOCK_DIALOG_ERROR,
- _(dialog_strings[type].error_text),
- error->message,
- GTK_STOCK_CLOSE, GTK_RESPONSE_ACCEPT,
- NULL);
+ xfce_dialog_show_warning (NULL,
+ error->message,
+ _(dialog_strings[type].error_text));
g_error_free(error);
}
}
More information about the Xfce4-commits
mailing list