diff options
author | Matthias Clasen <mclasen@fedoraproject.org> | 2008-08-05 16:44:17 +0000 |
---|---|---|
committer | Matthias Clasen <mclasen@fedoraproject.org> | 2008-08-05 16:44:17 +0000 |
commit | 5f3946cc287e244587900764d08ae66bbd74fb6c (patch) | |
tree | 0f8e57ced0864e7d391f785be7537b8b8ef0059b | |
parent | e05b8ced42a68e16e0690e2b790c9dcf87713ee4 (diff) | |
download | gnome-panel-5f3946cc287e244587900764d08ae66bbd74fb6c.tar.gz gnome-panel-5f3946cc287e244587900764d08ae66bbd74fb6c.tar.xz gnome-panel-5f3946cc287e244587900764d08ae66bbd74fb6c.zip |
2.23.6
-rw-r--r-- | .cvsignore | 2 | ||||
-rw-r--r-- | gnome-panel-2.13.5-switch-user.patch | 15 | ||||
-rw-r--r-- | gnome-panel-2.19.5-vendor.patch | 29 | ||||
-rw-r--r-- | gnome-panel-2.22.0-ck-shutdown.patch | 1193 | ||||
-rw-r--r-- | gnome-panel-larger-find-window.patch | 12 | ||||
-rw-r--r-- | gnome-panel-launch-with-gio.patch | 127 | ||||
-rw-r--r-- | gnome-panel-use-gio.patch | 15 | ||||
-rw-r--r-- | gnome-panel.spec | 17 | ||||
-rw-r--r-- | icon-names.patch | 24 | ||||
-rw-r--r-- | preferred-apps.patch | 42 | ||||
-rw-r--r-- | sources | 2 | ||||
-rw-r--r-- | timezone-debug.patch | 12 |
12 files changed, 28 insertions, 1462 deletions
@@ -1 +1 @@ -gnome-panel-2.23.5.tar.bz2 +gnome-panel-2.23.6.tar.bz2 diff --git a/gnome-panel-2.13.5-switch-user.patch b/gnome-panel-2.13.5-switch-user.patch deleted file mode 100644 index 9deb8e4..0000000 --- a/gnome-panel-2.13.5-switch-user.patch +++ /dev/null @@ -1,15 +0,0 @@ ---- gnome-panel-2.13.5/gnome-panel/panel-logout.c.switch-user 2006-01-20 09:43:52.000000000 -0500 -+++ gnome-panel-2.13.5/gnome-panel/panel-logout.c 2006-01-20 09:44:26.000000000 -0500 -@@ -205,10 +205,12 @@ - // FIXME set default button - logout_dialog->priv->default_response = PANEL_LOGOUT_DIALOG_LOGOUT; - -+#if 0 - //FIXME is gdm running? - gtk_dialog_add_button (GTK_DIALOG (logout_dialog), - _("_Switch User"), - PANEL_LOGOUT_RESPONSE_SWITCH_USER); -+#endif - gtk_dialog_add_button (GTK_DIALOG (logout_dialog), - GTK_STOCK_CANCEL, - GTK_RESPONSE_CANCEL); diff --git a/gnome-panel-2.19.5-vendor.patch b/gnome-panel-2.19.5-vendor.patch deleted file mode 100644 index 0afbf46..0000000 --- a/gnome-panel-2.19.5-vendor.patch +++ /dev/null @@ -1,29 +0,0 @@ ---- gnome-panel-2.17.91.svn20070207/gnome-panel/panel-menu-items.c.vendor 2007-02-07 00:18:07.000000000 -0500 -+++ gnome-panel-2.17.91.svn20070207/gnome-panel/panel-menu-items.c 2007-02-07 01:07:52.000000000 -0500 -@@ -611,7 +611,7 @@ - COMPUTER_NAME_KEY, - NULL); - panel_menu_items_append_from_desktop (places_menu, -- "nautilus-computer.desktop", -+ "gnome-nautilus-computer.desktop", - gconf_name); - if (gconf_name) - g_free (gconf_name); -@@ -624,7 +624,7 @@ - add_menu_separator (places_menu); - - panel_menu_items_append_from_desktop (places_menu, -- "network-scheme.desktop", -+ "gnome-network-scheme.desktop", - NULL); - panel_place_menu_item_append_volumes (places_menu, TRUE); - -@@ -715,7 +715,7 @@ - if (add_separator) - add_menu_separator (menu); - -- panel_menu_items_append_from_desktop (menu, "yelp.desktop", NULL); -+ panel_menu_items_append_from_desktop (menu, "gnome-yelp.desktop", NULL); - panel_menu_items_append_from_desktop (menu, "gnome-about.desktop", NULL); - - if (parent->priv->append_lock_logout) diff --git a/gnome-panel-2.22.0-ck-shutdown.patch b/gnome-panel-2.22.0-ck-shutdown.patch deleted file mode 100644 index a041d49..0000000 --- a/gnome-panel-2.22.0-ck-shutdown.patch +++ /dev/null @@ -1,1193 +0,0 @@ -diff -up gnome-panel-2.22.0/gnome-panel/Makefile.am.ck-shutdown gnome-panel-2.22.0/gnome-panel/Makefile.am ---- gnome-panel-2.22.0/gnome-panel/Makefile.am.ck-shutdown 2008-03-10 16:44:57.000000000 -0400 -+++ gnome-panel-2.22.0/gnome-panel/Makefile.am 2008-04-05 20:48:37.000000000 -0400 -@@ -16,6 +16,7 @@ INCLUDES = \ - $(STANDARD_PROPERTIES_CFLAGS) \ - $(PANEL_CFLAGS) \ - $(PANELCONFIG_CFLAGS) \ -+ $(POLKIT_GNOME_CFLAGS) \ - $(WARN_CFLAGS) \ - $(NULL) - -@@ -98,6 +99,7 @@ panel_sources = \ - panel-logout.c \ - panel-gdm.c \ - panel-power-manager.c \ -+ panel-consolekit.c \ - panel-ditem-editor.c \ - panel-mount-operation.c \ - $(NULL) -@@ -148,6 +150,7 @@ panel_headers = \ - panel-logout.h \ - panel-gdm.h \ - panel-power-manager.h \ -+ panel-consolekit.h \ - panel-ditem-editor.h \ - panel-icon-names.h \ - panel-mount-operation.h \ -@@ -161,6 +164,7 @@ gnome_panel_SOURCES = \ - - gnome_panel_LDADD = \ - $(PANEL_LIBS) \ -+ $(POLKIT_GNOME_LIBS) \ - $(X_LIBS) - - gnome_panel_LDFLAGS = -export-dynamic -diff -up gnome-panel-2.22.0/gnome-panel/panel-action-button.c.ck-shutdown gnome-panel-2.22.0/gnome-panel/panel-action-button.c ---- gnome-panel-2.22.0/gnome-panel/panel-action-button.c.ck-shutdown 2008-04-05 20:48:37.000000000 -0400 -+++ gnome-panel-2.22.0/gnome-panel/panel-action-button.c 2008-04-05 20:48:37.000000000 -0400 -@@ -46,7 +46,6 @@ - #include "panel-lockdown.h" - #include "panel-logout.h" - #include "panel-compatibility.h" --#include "panel-gdm.h" - #include "panel-icon-names.h" - - G_DEFINE_TYPE (PanelActionButton, panel_action_button, BUTTON_TYPE_WIDGET); -@@ -183,8 +182,7 @@ static gboolean - panel_action_shutdown_reboot_is_disabled (void) - { - return (panel_lockdown_get_disable_log_out() || -- (!gdm_supports_logout_action (GDM_LOGOUT_ACTION_SHUTDOWN) && -- !gdm_supports_logout_action (GDM_LOGOUT_ACTION_REBOOT))); -+ !panel_logout_supports_shutdown_reboot ()); - } - - /* Run Application -diff -up /dev/null gnome-panel-2.22.0/gnome-panel/panel-consolekit.c ---- /dev/null 2008-04-05 22:04:35.194004710 -0400 -+++ gnome-panel-2.22.0/gnome-panel/panel-consolekit.c 2008-04-05 20:48:37.000000000 -0400 -@@ -0,0 +1,682 @@ -+/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- -+ * -+ * Copyright (C) 2008 Jon McCann <jmccann@redhat.com> -+ * -+ * This program is free software; you can redistribute it and/or modify -+ * it under the terms of the GNU General Public License as published by -+ * the Free Software Foundation; either version 2, or (at your option) -+ * any later version. -+ * -+ * This program is distributed in the hope that it will be useful, -+ * but WITHOUT ANY WARRANTY; without even the implied warranty of -+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -+ * GNU General Public License for more details. -+ * -+ * You should have received a copy of the GNU General Public License -+ * along with this program; if not, write to the Free Software -+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA -+ * 02111-1307, USA. -+ */ -+ -+#include "config.h" -+ -+#include <errno.h> -+#include <string.h> -+#include <unistd.h> -+ -+#include <glib.h> -+#include <glib-object.h> -+#include <glib/gi18n.h> -+ -+#include <dbus/dbus-glib.h> -+ -+#ifdef HAVE_POLKIT -+#include <polkit-gnome/polkit-gnome.h> -+#endif -+ -+#include "panel-consolekit.h" -+ -+#define CK_NAME "org.freedesktop.ConsoleKit" -+#define CK_PATH "/org/freedesktop/ConsoleKit" -+#define CK_INTERFACE "org.freedesktop.ConsoleKit" -+ -+#define CK_MANAGER_PATH "/org/freedesktop/ConsoleKit/Manager" -+#define CK_MANAGER_INTERFACE "org.freedesktop.ConsoleKit.Manager" -+#define CK_SEAT_INTERFACE "org.freedesktop.ConsoleKit.Seat" -+#define CK_SESSION_INTERFACE "org.freedesktop.ConsoleKit.Session" -+ -+#define PANEL_CONSOLEKIT_GET_PRIVATE(o) (G_TYPE_INSTANCE_GET_PRIVATE ((o), PANEL_TYPE_CONSOLEKIT, PanelConsolekitPrivate)) -+ -+struct _PanelConsolekitPrivate { -+ DBusGConnection *dbus_connection; -+ DBusGProxy *bus_proxy; -+ DBusGProxy *ck_proxy; -+ guint32 is_connected : 1; -+}; -+ -+enum { -+ PROP_0 = 0, -+ PROP_IS_CONNECTED -+}; -+ -+enum { -+ REQUEST_COMPLETED = 0, -+ LAST_SIGNAL -+}; -+ -+static guint signals [LAST_SIGNAL]; -+ -+static void panel_consolekit_class_init (PanelConsolekitClass *klass); -+static void panel_consolekit_init (PanelConsolekit *ck); -+static void panel_consolekit_finalize (GObject *object); -+static void panel_consolekit_on_name_owner_changed (DBusGProxy *bus_proxy, -+ const char *name, -+ const char *prev_owner, -+ const char *new_owner, -+ PanelConsolekit *manager); -+ -+G_DEFINE_TYPE (PanelConsolekit, panel_consolekit, G_TYPE_OBJECT); -+ -+static void -+panel_consolekit_get_property (GObject *object, -+ guint prop_id, -+ GValue *value, -+ GParamSpec *pspec) -+{ -+ PanelConsolekit *manager = PANEL_CONSOLEKIT (object); -+ -+ switch (prop_id) { -+ case PROP_IS_CONNECTED: -+ g_value_set_boolean (value, -+ manager->priv->is_connected); -+ break; -+ -+ default: -+ G_OBJECT_WARN_INVALID_PROPERTY_ID (object, -+ prop_id, -+ pspec); -+ } -+} -+ -+static void -+panel_consolekit_class_init (PanelConsolekitClass *manager_class) -+{ -+ GObjectClass *object_class; -+ GParamSpec *param_spec; -+ -+ object_class = G_OBJECT_CLASS (manager_class); -+ -+ object_class->finalize = panel_consolekit_finalize; -+ object_class->get_property = panel_consolekit_get_property; -+ -+ param_spec = g_param_spec_boolean ("is-connected", -+ "Is connected", -+ "Whether the panel is connected to ConsoleKit", -+ FALSE, -+ G_PARAM_READABLE); -+ g_object_class_install_property (object_class, PROP_IS_CONNECTED, -+ param_spec); -+ -+ signals [REQUEST_COMPLETED] = -+ g_signal_new ("request-completed", -+ G_OBJECT_CLASS_TYPE (object_class), -+ G_SIGNAL_RUN_LAST, -+ G_STRUCT_OFFSET (PanelConsolekitClass, request_completed), -+ NULL, -+ NULL, -+ g_cclosure_marshal_VOID__POINTER, -+ G_TYPE_NONE, -+ 1, G_TYPE_POINTER); -+ -+ g_type_class_add_private (manager_class, -+ sizeof (PanelConsolekitPrivate)); -+} -+ -+static gboolean -+panel_consolekit_ensure_ck_connection (PanelConsolekit *manager, -+ GError **error) -+{ -+ GError *connection_error; -+ gboolean is_connected; -+ -+ connection_error = NULL; -+ if (manager->priv->dbus_connection == NULL) { -+ manager->priv->dbus_connection = dbus_g_bus_get (DBUS_BUS_SYSTEM, -+ &connection_error); -+ -+ if (manager->priv->dbus_connection == NULL) { -+ g_propagate_error (error, connection_error); -+ is_connected = FALSE; -+ goto out; -+ } -+ } -+ -+ if (manager->priv->bus_proxy == NULL) { -+ manager->priv->bus_proxy = -+ dbus_g_proxy_new_for_name_owner (manager->priv->dbus_connection, -+ DBUS_SERVICE_DBUS, -+ DBUS_PATH_DBUS, -+ DBUS_INTERFACE_DBUS, -+ &connection_error); -+ -+ if (manager->priv->bus_proxy == NULL) { -+ g_propagate_error (error, connection_error); -+ is_connected = FALSE; -+ goto out; -+ } -+ -+ dbus_g_proxy_add_signal (manager->priv->bus_proxy, -+ "NameOwnerChanged", -+ G_TYPE_STRING, -+ G_TYPE_STRING, -+ G_TYPE_STRING, -+ G_TYPE_INVALID); -+ dbus_g_proxy_connect_signal (manager->priv->bus_proxy, -+ "NameOwnerChanged", -+ G_CALLBACK (panel_consolekit_on_name_owner_changed), -+ manager, NULL); -+ } -+ -+ if (manager->priv->ck_proxy == NULL) { -+ manager->priv->ck_proxy = -+ dbus_g_proxy_new_for_name_owner (manager->priv->dbus_connection, -+ "org.freedesktop.ConsoleKit", -+ "/org/freedesktop/ConsoleKit/Manager", -+ "org.freedesktop.ConsoleKit.Manager", -+ &connection_error); -+ -+ if (manager->priv->ck_proxy == NULL) { -+ g_propagate_error (error, connection_error); -+ is_connected = FALSE; -+ goto out; -+ } -+ } -+ is_connected = TRUE; -+ -+out: -+ if (manager->priv->is_connected != is_connected) { -+ manager->priv->is_connected = is_connected; -+ g_object_notify (G_OBJECT (manager), "is-connected"); -+ } -+ -+ if (!is_connected) { -+ if (manager->priv->dbus_connection == NULL) { -+ if (manager->priv->bus_proxy != NULL) { -+ g_object_unref (manager->priv->bus_proxy); -+ manager->priv->bus_proxy = NULL; -+ } -+ -+ if (manager->priv->ck_proxy != NULL) { -+ g_object_unref (manager->priv->ck_proxy); -+ manager->priv->ck_proxy = NULL; -+ } -+ } else if (manager->priv->bus_proxy == NULL) { -+ if (manager->priv->ck_proxy != NULL) { -+ g_object_unref (manager->priv->ck_proxy); -+ manager->priv->ck_proxy = NULL; -+ } -+ } -+ } -+ -+ return is_connected; -+} -+ -+static void -+panel_consolekit_on_name_owner_changed (DBusGProxy *bus_proxy, -+ const char *name, -+ const char *prev_owner, -+ const char *new_owner, -+ PanelConsolekit *manager) -+{ -+ if (name != NULL && strcmp (name, "org.freedesktop.ConsoleKit") != 0) -+ return; -+ -+ if (manager->priv->ck_proxy != NULL) { -+ g_object_unref (manager->priv->ck_proxy); -+ manager->priv->ck_proxy = NULL; -+ } -+ -+ panel_consolekit_ensure_ck_connection (manager, NULL); -+} -+ -+static void -+panel_consolekit_init (PanelConsolekit *manager) -+{ -+ GError *error; -+ -+ manager->priv = PANEL_CONSOLEKIT_GET_PRIVATE (manager); -+ -+ error = NULL; -+ if (!panel_consolekit_ensure_ck_connection (manager, &error)) { -+ g_message ("Could not connect to ConsoleKit: %s", -+ error->message); -+ g_error_free (error); -+ } -+} -+ -+static void -+panel_consolekit_finalize (GObject *object) -+{ -+ PanelConsolekit *manager; -+ GObjectClass *parent_class; -+ -+ manager = PANEL_CONSOLEKIT (object); -+ -+ parent_class = G_OBJECT_CLASS (panel_consolekit_parent_class); -+ -+ if (manager->priv->bus_proxy != NULL) { -+ g_object_unref (manager->priv->bus_proxy); -+ } -+ -+ if (manager->priv->ck_proxy != NULL) { -+ g_object_unref (manager->priv->ck_proxy); -+ } -+ -+ if (parent_class->finalize != NULL) -+ parent_class->finalize (object); -+} -+ -+GQuark -+panel_consolekit_error_quark (void) -+{ -+ static GQuark error_quark = 0; -+ -+ if (error_quark == 0) -+ error_quark = g_quark_from_static_string ("panel-consolekit-error"); -+ -+ return error_quark; -+} -+ -+PanelConsolekit * -+panel_consolekit_new (void) -+{ -+ PanelConsolekit *manager; -+ -+ manager = g_object_new (PANEL_TYPE_CONSOLEKIT, NULL); -+ -+ return manager; -+} -+ -+static gboolean -+try_system_stop (DBusGConnection *connection, -+ GError **error) -+{ -+ DBusGProxy *proxy; -+ gboolean res; -+ -+ proxy = dbus_g_proxy_new_for_name (connection, -+ CK_NAME, -+ CK_MANAGER_PATH, -+ CK_MANAGER_INTERFACE); -+ res = dbus_g_proxy_call_with_timeout (proxy, -+ "Stop", -+ INT_MAX, -+ error, -+ /* parameters: */ -+ G_TYPE_INVALID, -+ /* return values: */ -+ G_TYPE_INVALID); -+ return res; -+} -+ -+static gboolean -+try_system_restart (DBusGConnection *connection, -+ GError **error) -+{ -+ DBusGProxy *proxy; -+ gboolean res; -+ -+ proxy = dbus_g_proxy_new_for_name (connection, -+ CK_NAME, -+ CK_MANAGER_PATH, -+ CK_MANAGER_INTERFACE); -+ res = dbus_g_proxy_call_with_timeout (proxy, -+ "Restart", -+ INT_MAX, -+ error, -+ /* parameters: */ -+ G_TYPE_INVALID, -+ /* return values: */ -+ G_TYPE_INVALID); -+ return res; -+} -+ -+static void -+emit_restart_complete (PanelConsolekit *manager, -+ const char *error_message) -+{ -+ GError *call_error; -+ -+ call_error = NULL; -+ -+ if (error_message != NULL) { -+ call_error = g_error_new_literal (PANEL_CONSOLEKIT_ERROR, -+ PANEL_CONSOLEKIT_ERROR_RESTARTING, -+ error_message); -+ } -+ -+ g_signal_emit (G_OBJECT (manager), -+ signals [REQUEST_COMPLETED], -+ 0, call_error); -+ if (call_error != NULL) { -+ g_error_free (call_error); -+ } -+} -+ -+static void -+emit_stop_complete (PanelConsolekit *manager, -+ GError *error) -+{ -+ GError *call_error; -+ -+ call_error = NULL; -+ -+ if (error != NULL) { -+ call_error = g_error_new_literal (PANEL_CONSOLEKIT_ERROR, -+ PANEL_CONSOLEKIT_ERROR_STOPPING, -+ error->message); -+ } -+ -+ g_signal_emit (G_OBJECT (manager), -+ signals [REQUEST_COMPLETED], -+ 0, call_error); -+ if (call_error != NULL) { -+ g_error_free (call_error); -+ } -+} -+ -+#ifdef HAVE_POLKIT -+static void -+system_restart_auth_cb (PolKitAction *action, -+ gboolean gained_privilege, -+ GError *error, -+ PanelConsolekit *manager) -+{ -+ GError *local_error; -+ gboolean res; -+ -+ if (! gained_privilege) { -+ if (error != NULL) { -+ emit_restart_complete (manager, error->message); -+ } -+ return; -+ } -+ -+ local_error = NULL; -+ res = try_system_restart (manager->priv->dbus_connection, &local_error); -+ if (! res) { -+ g_warning ("Unable to restart system: %s", local_error->message); -+ emit_restart_complete (manager, local_error->message); -+ g_error_free (local_error); -+ return; -+ } -+} -+ -+static void -+system_stop_auth_cb (PolKitAction *action, -+ gboolean gained_privilege, -+ GError *error, -+ PanelConsolekit *manager) -+{ -+ GError *local_error; -+ gboolean res; -+ -+ if (! gained_privilege) { -+ if (error != NULL) { -+ emit_stop_complete (manager, error); -+ } -+ return; -+ } -+ -+ local_error = NULL; -+ res = try_system_stop (manager->priv->dbus_connection, &local_error); -+ if (! res) { -+ g_warning ("Unable to stop system: %s", local_error->message); -+ emit_stop_complete (manager, local_error); -+ g_error_free (local_error); -+ return; -+ } -+} -+ -+static PolKitAction * -+get_action_from_error (GError *error) -+{ -+ PolKitAction *action; -+ char *paction; -+ char *p; -+ -+ action = polkit_action_new (); -+ -+ paction = NULL; -+ if (g_str_has_prefix (error->message, "Not privileged for action: ")) { -+ paction = g_strdup (error->message + strlen ("Not privileged for action: ")); -+ p = strchr (paction, ' '); -+ if (p) -+ *p = '\0'; -+ } -+ polkit_action_set_action_id (action, paction); -+ -+ g_free (paction); -+ -+ return action; -+} -+ -+static PolKitResult -+get_result_from_error (GError *error) -+{ -+ PolKitResult result = POLKIT_RESULT_UNKNOWN; -+ const char *p; -+ -+ p = strrchr (error->message, ' '); -+ if (p) { -+ p++; -+ polkit_result_from_string_representation (p, &result); -+ } -+ -+ return result; -+} -+ -+#endif /* HAVE_POLKIT */ -+ -+static void -+request_restart_priv (PanelConsolekit *manager, -+ GError *error) -+{ -+#ifdef HAVE_POLKIT -+ gboolean res = FALSE; -+ char *error_message = NULL; -+ PolKitAction *action; -+ PolKitAction *action2; -+ PolKitResult result; -+ guint xid; -+ pid_t pid; -+ GError *local_error; -+ -+ action = get_action_from_error (error); -+ result = get_result_from_error (error); -+ -+ if (result == POLKIT_RESULT_NO) { -+ action2 = polkit_action_new (); -+ polkit_action_set_action_id (action2, "org.freedesktop.consolekit.system.restart-multiple-users"); -+ if (polkit_action_equal (action, action2)) { -+ emit_restart_complete (manager, _("You are not allowed to restart the computer " -+ "because multiple users are logged in")); -+ } -+ else { -+ emit_restart_complete (manager, _("You are not allowed to restart the computer")); -+ } -+ polkit_action_unref (action); -+ polkit_action_unref (action2); -+ -+ return; -+ } -+ -+ -+ xid = 0; -+ pid = getpid (); -+ -+ local_error = NULL; -+ res = polkit_gnome_auth_obtain (action, -+ xid, -+ pid, -+ (PolKitGnomeAuthCB) system_restart_auth_cb, -+ manager, -+ &local_error); -+ polkit_action_unref (action); -+ if (local_error != NULL) { -+ error_message = g_strdup (local_error->message); -+ g_error_free (local_error); -+ } -+ -+ if (! res) { -+ emit_restart_complete (manager, error_message); -+ g_free (error_message); -+ } -+#else -+ g_assert_not_reached (); -+#endif /* HAVE POLKIT */ -+} -+ -+static void -+request_stop_priv (PanelConsolekit *manager, -+ GError *error) -+{ -+#ifdef HAVE_POLKIT -+ gboolean res = FALSE; -+ char *error_message = NULL; -+ PolKitAction *action; -+ PolKitAction *action2; -+ PolKitResult result; -+ guint xid; -+ pid_t pid; -+ GError *local_error; -+ -+ result = get_result_from_error (error); -+ action = get_action_from_error (error); -+ -+ if (result == POLKIT_RESULT_NO) { -+ action2 = polkit_action_new (); -+ polkit_action_set_action_id (action2, "org.freedesktop.consolekit.system.stop-multiple-users"); -+ if (polkit_action_equal (action, action2)) { -+ emit_restart_complete (manager, _("You are not allowed to stop the computer " -+ "because multiple users are logged in")); -+ } -+ else { -+ emit_restart_complete (manager, _("You are not allowed to stop the computer")); -+ } -+ polkit_action_unref (action); -+ polkit_action_unref (action2); -+ -+ return; -+ } -+ -+ xid = 0; -+ pid = getpid (); -+ -+ xid = 0; -+ pid = getpid (); -+ -+ local_error = NULL; -+ res = polkit_gnome_auth_obtain (action, -+ xid, -+ pid, -+ (PolKitGnomeAuthCB) system_stop_auth_cb, -+ manager, -+ &local_error); -+ polkit_action_unref (action); -+ if (local_error != NULL) { -+ error_message = g_strdup (local_error->message); -+ g_error_free (local_error); -+ } -+ if (! res) { -+ emit_stop_complete (manager, error_message); -+ g_free (error_message); -+ } -+#else -+ g_assert_not_reached (); -+#endif /* HAVE POLKIT */ -+} -+ -+void -+panel_consolekit_attempt_restart (PanelConsolekit *manager) -+{ -+ gboolean res; -+ GError *error; -+ -+ error = NULL; -+ -+ if (!panel_consolekit_ensure_ck_connection (manager, &error)) { -+ g_warning ("Could not connect to ConsoleKit: %s", -+ error->message); -+ g_error_free (error); -+ return; -+ } -+ -+ res = try_system_restart (manager->priv->dbus_connection, &error); -+ if (! res) { -+ if (dbus_g_error_has_name (error, "org.freedesktop.ConsoleKit.Manager.NotPrivileged")) { -+ request_restart_priv (manager, error); -+ } else { -+ emit_restart_complete (manager, error); -+ } -+ g_error_free (error); -+ } -+} -+ -+void -+panel_consolekit_attempt_stop (PanelConsolekit *manager) -+{ -+ gboolean res; -+ GError *error; -+ -+ error = NULL; -+ -+ if (!panel_consolekit_ensure_ck_connection (manager, &error)) { -+ g_warning ("Could not connect to ConsoleKit: %s", -+ error->message); -+ g_error_free (error); -+ return; -+ } -+ -+ res = try_system_stop (manager->priv->dbus_connection, &error); -+ if (! res) { -+ if (dbus_g_error_has_name (error, "org.freedesktop.ConsoleKit.Manager.NotPrivileged")) { -+ request_stop_priv (manager, error); -+ } else { -+ emit_stop_complete (manager, error); -+ } -+ g_error_free (error); -+ } -+} -+ -+gboolean -+panel_consolekit_can_restart (PanelConsolekit *manager) -+{ -+#ifdef HAVE_POLKIT -+ return panel_consolekit_ensure_ck_connection (manager, NULL); -+#else -+ return FALSE; -+#endif -+} -+ -+gboolean -+panel_consolekit_can_stop (PanelConsolekit *manager) -+{ -+#ifdef HAVE_POLKIT -+ return panel_consolekit_ensure_ck_connection (manager, NULL); -+#else -+ return FALSE; -+#endif -+} -+ -+PanelConsolekit * -+panel_get_consolekit (void) -+{ -+ static PanelConsolekit *manager = NULL; -+ -+ if (manager == NULL) { -+ manager = panel_consolekit_new (); -+ } -+ -+ return g_object_ref (manager); -+} -diff -up /dev/null gnome-panel-2.22.0/gnome-panel/panel-consolekit.h ---- /dev/null 2008-04-05 22:04:35.194004710 -0400 -+++ gnome-panel-2.22.0/gnome-panel/panel-consolekit.h 2008-04-05 20:48:37.000000000 -0400 -@@ -0,0 +1,77 @@ -+/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- -+ * -+ * Copyright (C) 2008 Jon McCann <jmccann@redhat.com> -+ * -+ * This program is free software; you can redistribute it and/or -+ * modify it under the terms of the GNU General Public License as -+ * published by the Free Software Foundation; either version 2 of the -+ * License, or (at your option) any later version. -+ * -+ * This program is distributed in the hope that it will be useful, but -+ * WITHOUT ANY WARRANTY; without even the implied warranty of -+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -+ * General Public License for more details. -+ * -+ * You should have received a copy of the GNU General Public License -+ * along with this program; if not, write to the Free Software -+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA -+ * 02111-1307, USA. -+ * -+ * Authors: -+ * Jon McCann <jmccann@redhat.com> -+ */ -+ -+#ifndef PANEL_CONSOLEKIT_H -+#define PANEL_CONSOLEKIT_H -+ -+#include <glib.h> -+#include <glib-object.h> -+ -+G_BEGIN_DECLS -+ -+#define PANEL_TYPE_CONSOLEKIT (panel_consolekit_get_type ()) -+#define PANEL_CONSOLEKIT(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), PANEL_TYPE_CONSOLEKIT, PanelConsolekit)) -+#define PANEL_CONSOLEKIT_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), PANEL_TYPE_CONSOLEKIT, PanelConsolekitClass)) -+#define PANEL_IS_CONSOLEKIT(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), PANEL_TYPE_CONSOLEKIT)) -+#define PANEL_IS_CONSOLEKIT_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), PANEL_TYPE_CONSOLEKIT)) -+#define PANEL_CONSOLEKIT_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS((obj), PANEL_TYPE_CONSOLEKIT, PanelConsolekitClass)) -+#define PANEL_CONSOLEKIT_ERROR (panel_consolekit_error_quark ()) -+ -+typedef struct _PanelConsolekit PanelConsolekit; -+typedef struct _PanelConsolekitClass PanelConsolekitClass; -+typedef struct _PanelConsolekitPrivate PanelConsolekitPrivate; -+typedef enum _PanelConsolekitError PanelConsolekitError; -+ -+struct _PanelConsolekit { -+ GObject parent; -+ PanelConsolekitPrivate *priv; -+}; -+ -+struct _PanelConsolekitClass { -+ GObjectClass parent_class; -+ -+ void (* request_completed) (PanelConsolekit *manager, -+ GError *error); -+}; -+ -+enum _PanelConsolekitError { -+ PANEL_CONSOLEKIT_ERROR_RESTARTING = 0, -+ PANEL_CONSOLEKIT_ERROR_STOPPING -+}; -+ -+GType panel_consolekit_get_type (void); -+GQuark panel_consolekit_error_quark (void); -+ -+PanelConsolekit *panel_consolekit_new (void) G_GNUC_MALLOC; -+ -+gboolean panel_consolekit_can_stop (PanelConsolekit *manager); -+gboolean panel_consolekit_can_restart (PanelConsolekit *manager); -+ -+void panel_consolekit_attempt_stop (PanelConsolekit *manager); -+void panel_consolekit_attempt_restart (PanelConsolekit *manager); -+ -+PanelConsolekit *panel_get_consolekit (void); -+ -+G_END_DECLS -+ -+#endif /* PANEL_CONSOLEKIT_H */ -diff -up gnome-panel-2.22.0/gnome-panel/panel-logout.c.ck-shutdown gnome-panel-2.22.0/gnome-panel/panel-logout.c ---- gnome-panel-2.22.0/gnome-panel/panel-logout.c.ck-shutdown 2008-04-05 20:48:37.000000000 -0400 -+++ gnome-panel-2.22.0/gnome-panel/panel-logout.c 2008-04-05 22:18:24.000000000 -0400 -@@ -1,4 +1,5 @@ --/* -+/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- -+ * - * panel-logout.c: - * - * Copyright (C) 2006 Vincent Untz -@@ -35,8 +36,10 @@ - #include "panel-logout.h" - #include "panel-gdm.h" - #include "panel-power-manager.h" -+#include "panel-consolekit.h" - #include "panel-session.h" - #include "panel-icon-names.h" -+#include "panel-gconf.h" - - #define PANEL_LOGOUT_DIALOG_GET_PRIVATE(o) (G_TYPE_INSTANCE_GET_PRIVATE ((o), PANEL_TYPE_LOGOUT_DIALOG, PanelLogoutDialogPrivate)) - -@@ -55,6 +58,7 @@ struct _PanelLogoutDialogPrivate { - PanelLogoutDialogType type; - - PanelPowerManager *power_manager; -+ PanelConsolekit *consolekit; - - int timeout; - unsigned int timeout_id; -@@ -76,7 +80,7 @@ enum { - }; - G_DEFINE_TYPE (PanelLogoutDialog, panel_logout, GTK_TYPE_MESSAGE_DIALOG); - --static void -+static void - panel_logout_set_property (GObject *object, - guint prop_id, - const GValue *value, -@@ -91,7 +95,7 @@ panel_logout_set_property (GObject - } - } - --static void -+static void - panel_logout_get_property (GObject *object, - guint prop_id, - GValue *value, -@@ -130,6 +134,57 @@ panel_logout_class_init (PanelLogoutDial - } - - static void -+ck_restart_error_window (GError *error) -+{ -+ GtkWidget *dialog; -+ const char *primary; -+ -+ g_assert (error != NULL); -+ -+ switch (error->code) { -+ case PANEL_CONSOLEKIT_ERROR_RESTARTING: -+ primary = _("Unable to restart system"); -+ break; -+ case PANEL_CONSOLEKIT_ERROR_STOPPING: -+ primary = _("Unable to stop system"); -+ break; -+ default: -+ g_assert_not_reached (); -+ } -+ -+ dialog = gtk_message_dialog_new (NULL, 0, -+ GTK_MESSAGE_ERROR, -+ GTK_BUTTONS_NONE, -+ primary); -+ -+ gtk_message_dialog_format_secondary_text (GTK_MESSAGE_DIALOG (dialog), -+ "%s", error->message); -+ -+ gtk_dialog_add_buttons (GTK_DIALOG (dialog), -+ GTK_STOCK_CLOSE, -+ NULL); -+ -+ gtk_dialog_set_default_response (GTK_DIALOG (dialog), -+ GTK_RESPONSE_CLOSE); -+ gtk_window_set_skip_taskbar_hint (GTK_WINDOW (dialog), FALSE); -+ gtk_window_set_title (GTK_WINDOW (dialog), ""); -+ -+ g_signal_connect (dialog, "response", -+ G_CALLBACK (gtk_widget_destroy), NULL); -+ -+ gtk_widget_show (dialog); -+} -+ -+static void -+on_ck_request_completed (PanelConsolekit *panel_consolekit, -+ GError *error) -+{ -+ if (error) { -+ ck_restart_error_window (error); -+ } -+} -+ -+static void - panel_logout_init (PanelLogoutDialog *logout_dialog) - { - logout_dialog->priv = PANEL_LOGOUT_DIALOG_GET_PRIVATE (logout_dialog); -@@ -146,6 +201,10 @@ panel_logout_init (PanelLogoutDialog *lo - GTK_WIN_POS_CENTER_ALWAYS); - - logout_dialog->priv->power_manager = panel_get_power_manager (); -+ logout_dialog->priv->consolekit = panel_get_consolekit (); -+ g_signal_connect (logout_dialog->priv->consolekit, -+ "request-completed", -+ G_CALLBACK (on_ck_request_completed), NULL); - - g_signal_connect (logout_dialog, "destroy", - G_CALLBACK (panel_logout_destroy), NULL); -@@ -163,37 +222,129 @@ panel_logout_destroy (PanelLogoutDialog - - g_object_unref (logout_dialog->priv->power_manager); - logout_dialog->priv->power_manager = NULL; -+ g_object_unref (logout_dialog->priv->consolekit); -+ logout_dialog->priv->consolekit = NULL; - - current_dialog = NULL; - } - -+static gboolean -+panel_logout_supports_reboot (PanelLogoutDialog *logout_dialog) -+{ -+ gboolean ret; -+ -+ ret = panel_consolekit_can_restart (logout_dialog->priv->consolekit); -+ if (!ret) { -+ ret = gdm_supports_logout_action (GDM_LOGOUT_ACTION_REBOOT); -+ } -+ return ret; -+} -+ -+static gboolean -+panel_logout_supports_shutdown (PanelLogoutDialog *logout_dialog) -+{ -+ gboolean ret; -+ -+ ret = panel_consolekit_can_stop (logout_dialog->priv->consolekit); -+ if (!ret) { -+ ret = gdm_supports_logout_action (GDM_LOGOUT_ACTION_SHUTDOWN); -+ } -+ return ret; -+} -+ -+gboolean -+panel_logout_supports_shutdown_reboot (void) -+{ -+ PanelConsolekit *consolekit; -+ gboolean ret; -+ -+ ret = FALSE; -+ -+ /* if we can do any then return true */ -+ -+ consolekit = panel_get_consolekit (); -+ if (consolekit != NULL) { -+ ret = panel_consolekit_can_restart (consolekit) -+ || panel_consolekit_can_stop (consolekit); -+ g_object_unref (consolekit); -+ } -+ -+ if (!ret) { -+ ret = gdm_supports_logout_action (GDM_LOGOUT_ACTION_REBOOT) -+ || gdm_supports_logout_action (GDM_LOGOUT_ACTION_SHUTDOWN); -+ } -+ -+ return ret; -+} -+ -+static void -+do_request_logout (PanelConsolekit *consolekit) -+{ -+ gdm_set_logout_action (GDM_LOGOUT_ACTION_NONE); -+ panel_session_request_logout (); -+} -+ -+static void -+maybe_request_session_save (void) -+{ -+ if (gconf_client_get_bool (panel_gconf_get_client (), -+ "/apps/gnome-session/options/auto_save_session", -+ NULL)) -+ panel_session_request_save (); -+} -+ -+static void -+do_request_reboot (PanelConsolekit *consolekit) -+{ -+ if (panel_consolekit_can_restart (consolekit)) { -+ gdm_set_logout_action (GDM_LOGOUT_ACTION_NONE); -+ maybe_request_session_save (); -+ panel_consolekit_attempt_restart (consolekit); -+ } else { -+ gdm_set_logout_action (GDM_LOGOUT_ACTION_REBOOT); -+ panel_session_request_logout (); -+ } -+} -+ -+static void -+do_request_shutdown (PanelConsolekit *consolekit) -+{ -+ if (panel_consolekit_can_stop (consolekit)) { -+ gdm_set_logout_action (GDM_LOGOUT_ACTION_NONE); -+ maybe_request_session_save (); -+ panel_consolekit_attempt_stop (consolekit); -+ } else { -+ gdm_set_logout_action (GDM_LOGOUT_ACTION_SHUTDOWN); -+ panel_session_request_logout (); -+ } -+} -+ - static void - panel_logout_response (PanelLogoutDialog *logout_dialog, - guint response_id, - gpointer data) - { - PanelPowerManager *power_manager; -+ PanelConsolekit *consolekit; - - power_manager = g_object_ref (logout_dialog->priv->power_manager); -+ consolekit = g_object_ref (logout_dialog->priv->consolekit); - gtk_widget_destroy (GTK_WIDGET (logout_dialog)); - - switch (response_id) { - case GTK_RESPONSE_CANCEL: - break; - case PANEL_LOGOUT_RESPONSE_LOGOUT: -- gdm_set_logout_action (GDM_LOGOUT_ACTION_NONE); -- panel_session_request_logout (); -+ do_request_logout (consolekit); - break; - case PANEL_LOGOUT_RESPONSE_SWITCH_USER: - gdm_new_login (); - break; - case PANEL_LOGOUT_RESPONSE_SHUTDOWN: -- gdm_set_logout_action (GDM_LOGOUT_ACTION_SHUTDOWN); -- panel_session_request_logout (); -+ do_request_shutdown (consolekit); - break; - case PANEL_LOGOUT_RESPONSE_REBOOT: -- gdm_set_logout_action (GDM_LOGOUT_ACTION_REBOOT); -- panel_session_request_logout (); -+ do_request_reboot (consolekit); - break; - case PANEL_LOGOUT_RESPONSE_STD: - if (panel_power_manager_can_hibernate (power_manager)) -@@ -210,6 +361,7 @@ panel_logout_response (PanelLogoutDialog - g_assert_not_reached (); - } - g_object_unref (power_manager); -+ g_object_unref (consolekit); - } - - static gboolean -@@ -363,7 +515,7 @@ panel_logout_new (PanelLogoutDialogType - _("_Hibernate"), - PANEL_LOGOUT_RESPONSE_STD); - -- if (gdm_supports_logout_action (GDM_LOGOUT_ACTION_REBOOT)) -+ if (panel_logout_supports_reboot (logout_dialog)) - gtk_dialog_add_button (GTK_DIALOG (logout_dialog), - _("_Restart"), - PANEL_LOGOUT_RESPONSE_REBOOT); -@@ -372,7 +524,7 @@ panel_logout_new (PanelLogoutDialogType - GTK_STOCK_CANCEL, - GTK_RESPONSE_CANCEL); - -- if (gdm_supports_logout_action (GDM_LOGOUT_ACTION_SHUTDOWN)) -+ if (panel_logout_supports_shutdown (logout_dialog)) - gtk_dialog_add_button (GTK_DIALOG (logout_dialog), - _("_Shut Down"), - PANEL_LOGOUT_RESPONSE_SHUTDOWN); -diff -up gnome-panel-2.22.0/gnome-panel/panel-logout.h.ck-shutdown gnome-panel-2.22.0/gnome-panel/panel-logout.h ---- gnome-panel-2.22.0/gnome-panel/panel-logout.h.ck-shutdown 2008-03-10 16:44:57.000000000 -0400 -+++ gnome-panel-2.22.0/gnome-panel/panel-logout.h 2008-04-05 20:48:37.000000000 -0400 -@@ -57,6 +57,8 @@ struct _PanelLogoutDialogClass { - - GType panel_logout_get_type (void) G_GNUC_CONST; - -+gboolean panel_logout_supports_shutdown_reboot (void); -+ - void panel_logout_new (PanelLogoutDialogType type, - GdkScreen *screen, - guint32 activate_time); -diff -up gnome-panel-2.22.0/gnome-panel/panel-session.c.ck-shutdown gnome-panel-2.22.0/gnome-panel/panel-session.c ---- gnome-panel-2.22.0/gnome-panel/panel-session.c.ck-shutdown 2008-03-10 16:44:57.000000000 -0400 -+++ gnome-panel-2.22.0/gnome-panel/panel-session.c 2008-04-05 20:48:37.000000000 -0400 -@@ -60,6 +60,34 @@ panel_session_request_logout (void) - recursion_guard--; - } - -+void -+panel_session_request_save (void) -+{ -+ GnomeClient *client; -+ static int recursion_guard = 0; -+ -+ if (recursion_guard) -+ return; -+ -+ recursion_guard++; -+ -+ if (!(client = gnome_master_client ())) -+ return; -+ -+ /* Only request a Global save. We only want a Local -+ * save if the user selects 'Save current setup' -+ * from the dialog. -+ */ -+ gnome_client_request_save (client, -+ GNOME_SAVE_GLOBAL, -+ FALSE, -+ GNOME_INTERACT_NONE, -+ TRUE, /* do not use the gnome-session gui */ -+ TRUE); -+ -+ recursion_guard--; -+} -+ - static void - panel_session_handle_die_request (GnomeClient *client) - { -diff -up gnome-panel-2.22.0/gnome-panel/panel-session.h.ck-shutdown gnome-panel-2.22.0/gnome-panel/panel-session.h ---- gnome-panel-2.22.0/gnome-panel/panel-session.h.ck-shutdown 2008-03-10 16:44:57.000000000 -0400 -+++ gnome-panel-2.22.0/gnome-panel/panel-session.h 2008-04-05 20:48:37.000000000 -0400 -@@ -30,6 +30,7 @@ G_BEGIN_DECLS - void panel_session_init (void); - void panel_session_do_not_restart (void); - void panel_session_request_logout (void); -+void panel_session_request_save (void); - - G_END_DECLS - -diff -up gnome-panel-2.22.0/gnome-panel/panel-toplevel.c.ck-shutdown gnome-panel-2.22.0/gnome-panel/panel-toplevel.c ---- gnome-panel-2.22.0/gnome-panel/panel-toplevel.c.ck-shutdown 2008-03-10 16:44:57.000000000 -0400 -+++ gnome-panel-2.22.0/gnome-panel/panel-toplevel.c 2008-04-05 20:48:37.000000000 -0400 -@@ -3329,7 +3329,8 @@ panel_toplevel_get_animation_time (Panel - } - - static void --panel_toplevel_start_animation (PanelToplevel *toplevel) -+panel_toplevel_start_animation (PanelToplevel *toplevel, -+ gboolean auto_hide) - { - GdkScreen *screen; - int monitor_width, monitor_height; -@@ -3480,7 +3481,7 @@ panel_toplevel_hide (PanelToplevel *t - } - - if (toplevel->priv->animate && GTK_WIDGET_REALIZED (toplevel)) -- panel_toplevel_start_animation (toplevel); -+ panel_toplevel_start_animation (toplevel, auto_hide); - else if (toplevel->priv->attached) - gtk_widget_hide (GTK_WIDGET (toplevel)); - -@@ -3528,7 +3529,7 @@ panel_toplevel_unhide (PanelToplevel *to - panel_toplevel_push_autohide_disabler (toplevel->priv->attach_toplevel); - - if (toplevel->priv->animate && GTK_WIDGET_REALIZED (toplevel)) -- panel_toplevel_start_animation (toplevel); -+ panel_toplevel_start_animation (toplevel, FALSE); - else if (toplevel->priv->attached) - gtk_widget_show (GTK_WIDGET (toplevel)); - diff --git a/gnome-panel-larger-find-window.patch b/gnome-panel-larger-find-window.patch deleted file mode 100644 index 087c37f..0000000 --- a/gnome-panel-larger-find-window.patch +++ /dev/null @@ -1,12 +0,0 @@ -diff -up gnome-panel-2.22.0/applets/clock/clock.glade.larger-find-window gnome-panel-2.22.0/applets/clock/clock.glade ---- gnome-panel-2.22.0/applets/clock/clock.glade.larger-find-window 2008-03-27 21:37:32.000000000 -0400 -+++ gnome-panel-2.22.0/applets/clock/clock.glade 2008-03-27 21:36:59.000000000 -0400 -@@ -822,6 +822,8 @@ South</property> - <property name="gravity">GDK_GRAVITY_NORTH_WEST</property> - <property name="focus_on_map">True</property> - <property name="urgency_hint">False</property> -+ <property name="default_width">400</property> -+ <property name="default_height">500</property> - - <child> - <widget class="GtkVBox" id="vbox25"> diff --git a/gnome-panel-launch-with-gio.patch b/gnome-panel-launch-with-gio.patch deleted file mode 100644 index d5531f8..0000000 --- a/gnome-panel-launch-with-gio.patch +++ /dev/null @@ -1,127 +0,0 @@ -diff -up gnome-panel-2.23.5/gnome-panel/panel-menu-items.c.launch-with-gio gnome-panel-2.23.5/gnome-panel/panel-menu-items.c ---- gnome-panel-2.23.5/gnome-panel/panel-menu-items.c.launch-with-gio 2008-07-22 22:37:50.000000000 -0400 -+++ gnome-panel-2.23.5/gnome-panel/panel-menu-items.c 2008-07-22 22:39:01.000000000 -0400 -@@ -41,6 +41,7 @@ - - #include <libgnome/gnome-url.h> - #include <libgnomeui/gnome-url.h> -+#include <libgnomeui/gnome-password-dialog.h> - - #include <libpanel-util/panel-glib.h> - #include <libpanel-util/panel-keyfile.h> -@@ -99,6 +100,51 @@ struct _PanelDesktopMenuItemPrivate { - guint append_lock_logout : 1; - }; - -+typedef struct { -+ GMountOperation *mount_op; -+ GdkScreen *screen; -+} MountOperationHandle; -+ -+static void -+mount_async_callback (GObject *source_object, -+ GAsyncResult *result, -+ gpointer user_data) -+{ -+ GError *error = NULL; -+ GFile *file; -+ MountOperationHandle *handle = user_data; -+ -+ file = G_FILE (source_object); -+ if (g_file_mount_enclosing_volume_finish (file, result, &error)) { -+ char *uri = g_file_get_uri (file); -+ // FIXME use an app launch context -+ g_app_info_launch_default_for_uri (uri, NULL, &error); -+ g_free (uri); -+ } -+ else { -+ if (!g_error_matches (error, G_IO_ERROR, G_IO_ERROR_PERMISSION_DENIED) && -+ !g_error_matches (error, G_IO_ERROR, G_IO_ERROR_FAILED_HANDLED)) { -+ char *primary, *escaped, *url; -+ url = g_file_get_uri (file); -+ escaped = g_markup_escape_text (url, -1); -+ g_free (url); -+ primary = g_strdup_printf (_("Could not open location '%s'"), -+ escaped); -+ g_free (escaped); -+ panel_error_dialog (NULL, handle->screen, -+ "cannot_show_url", TRUE, -+ primary, error->message); -+ g_free (primary); -+ } -+ g_error_free (error); -+ } -+ -+ if (handle->mount_op) -+ g_object_unref (handle->mount_op); -+ -+ g_free (handle); -+} -+ - static void - activate_uri_on_screen (const char *path, - GdkScreen *screen) -@@ -125,12 +171,28 @@ activate_uri_on_screen (const char *path - - command = g_strdup_printf ("nautilus --no-desktop %s", url); - gdk_spawn_command_line_on_screen (screen, command, &error); -- } else -+ } else { -+ // FIXME use an app launch context - g_app_info_launch_default_for_uri (url, NULL, &error); -- //gnome_url_show_on_screen (url, screen, &error); -+ } - - if (error != NULL) { -- if (error->code != GNOME_URL_ERROR_CANCELLED) { -+ if (g_error_matches (error, G_IO_ERROR, G_IO_ERROR_NOT_MOUNTED)) { -+ MountOperationHandle *handle; -+ -+ handle = g_new (MountOperationHandle, 1); -+ file = g_file_new_for_uri (url); -+ -+ /* If it's not mounted, try to mount it ourselves */ -+ handle->mount_op = panel_mount_operation_new (NULL); -+ handle->screen = screen; -+ -+ g_file_mount_enclosing_volume (file, G_MOUNT_MOUNT_NONE, handle->mount_op, -+ NULL, mount_async_callback, handle); -+ g_object_unref (file); -+ -+ } -+ else { - char *primary; - escaped = g_markup_escape_text (url, -1); - primary = g_strdup_printf (_("Could not open location '%s'"), -diff -up gnome-panel-2.23.5/gnome-panel/panel-mount-operation.c.launch-with-gio gnome-panel-2.23.5/gnome-panel/panel-mount-operation.c ---- gnome-panel-2.23.5/gnome-panel/panel-mount-operation.c.launch-with-gio 2008-07-22 17:50:58.000000000 -0400 -+++ gnome-panel-2.23.5/gnome-panel/panel-mount-operation.c 2008-07-22 22:37:50.000000000 -0400 -@@ -102,6 +102,18 @@ password_dialog_button_clicked (GtkDialo - anon = gnome_password_dialog_anon_selected (gpd); - g_mount_operation_set_anonymous (op, anon); - -+ switch (gnome_password_dialog_get_remember (gpd)) { -+ case GNOME_PASSWORD_DIALOG_REMEMBER_NOTHING: -+ g_mount_operation_set_password_save (op, G_PASSWORD_SAVE_NEVER); -+ break; -+ case GNOME_PASSWORD_DIALOG_REMEMBER_SESSION: -+ g_mount_operation_set_password_save (op, G_PASSWORD_SAVE_FOR_SESSION); -+ break; -+ case GNOME_PASSWORD_DIALOG_REMEMBER_FOREVER: -+ g_mount_operation_set_password_save (op, G_PASSWORD_SAVE_PERMANENTLY); -+ break; -+ } -+ - g_mount_operation_reply (op, G_MOUNT_OPERATION_HANDLED); - } else { - g_mount_operation_reply (op, G_MOUNT_OPERATION_ABORTED); -@@ -136,6 +148,9 @@ ask_password (GMountOperation *op, - flags & G_ASK_PASSWORD_NEED_DOMAIN); - gnome_password_dialog_set_show_userpass_buttons (GNOME_PASSWORD_DIALOG (dialog), - flags & G_ASK_PASSWORD_ANONYMOUS_SUPPORTED); -+ gnome_password_dialog_set_show_remember (GNOME_PASSWORD_DIALOG (dialog), -+ flags & G_ASK_PASSWORD_SAVING_SUPPORTED); -+ - if (default_domain) { - gnome_password_dialog_set_domain (GNOME_PASSWORD_DIALOG (dialog), - default_domain); diff --git a/gnome-panel-use-gio.patch b/gnome-panel-use-gio.patch deleted file mode 100644 index dcf1036..0000000 --- a/gnome-panel-use-gio.patch +++ /dev/null @@ -1,15 +0,0 @@ -diff -up gnome-panel-2.22.1.2/gnome-panel/panel-menu-items.c.use-gio gnome-panel-2.22.1.2/gnome-panel/panel-menu-items.c ---- gnome-panel-2.22.1.2/gnome-panel/panel-menu-items.c.use-gio 2008-04-18 22:48:16.000000000 -0400 -+++ gnome-panel-2.22.1.2/gnome-panel/panel-menu-items.c 2008-04-18 22:53:10.000000000 -0400 -@@ -125,8 +125,9 @@ activate_uri (GtkWidget *menuitem, - - command = g_strdup_printf ("nautilus --no-desktop %s", url); - gdk_spawn_command_line_on_screen (screen, command, &error); -- } else -- gnome_url_show_on_screen (url, screen, &error); -+ } else -+ g_app_info_launch_default_for_uri (url, NULL, &error); -+ //gnome_url_show_on_screen (url, screen, &error); - - if (error != NULL) { - if (error->code != GNOME_URL_ERROR_CANCELLED) { diff --git a/gnome-panel.spec b/gnome-panel.spec index 261a198..3c89ce8 100644 --- a/gnome-panel.spec +++ b/gnome-panel.spec @@ -22,8 +22,8 @@ Summary: GNOME panel Name: gnome-panel -Version: 2.23.5 -Release: 2%{?dist} +Version: 2.23.6 +Release: 1%{?dist} URL: http://www.gnome.org Source0: http://download.gnome.org/sources/gnome-panel/2.23/%{name}-%{version}.tar.bz2 @@ -110,13 +110,6 @@ Patch11: applet-error.patch # http://bugzilla.gnome.org/show_bug.cgi?id=520111 Patch24: gnome-panel-2.21.92-allow-spurious-view-done-signals.patch -# fixed upstream -Patch28: gnome-panel-larger-find-window.patch - -Patch33: gnome-panel-use-gio.patch -# http://bugzilla.gnome.org/show_bug.cgi?id=529243 -Patch34: gnome-panel-launch-with-gio.patch - Patch35: clock-wakeups.patch Conflicts: gnome-power-manager < 2.15.3 @@ -164,9 +157,6 @@ Panel Applets using the libpanel-applet library. %patch10 -p1 -b .preferred-apps %patch11 -p1 -b .applet-error %patch24 -p1 -b .allow-spurious-view-done-signals -%patch28 -p1 -b .larger-find-window -%patch33 -p1 -b .use-gio -%patch34 -p1 -b .launch-with-gio %patch35 -p1 -b .clock-wakeups . %{SOURCE6} @@ -354,6 +344,9 @@ fi %{_datadir}/gtk-doc/html/* %changelog +* Tue Aug 5 2008 Matthias Clasen <mclasen@redhat.com> - 2.23.6-1 +- Update to 2.23.6 + * Wed Jul 23 2008 Tom "spot" Callaway <tcallawa@redhat.com> - 2.23.5-2 - fix license tag diff --git a/icon-names.patch b/icon-names.patch deleted file mode 100644 index 8c9d850..0000000 --- a/icon-names.patch +++ /dev/null @@ -1,24 +0,0 @@ -diff -up gnome-panel-2.23.4/applets/wncklet/GNOME_Wncklet_Factory.server.in.in.icon-names gnome-panel-2.23.4/applets/wncklet/GNOME_Wncklet_Factory.server.in.in ---- gnome-panel-2.23.4/applets/wncklet/GNOME_Wncklet_Factory.server.in.in.icon-names 2008-07-18 21:54:05.000000000 -0400 -+++ gnome-panel-2.23.4/applets/wncklet/GNOME_Wncklet_Factory.server.in.in 2008-07-18 21:54:20.000000000 -0400 -@@ -122,7 +122,7 @@ - </oaf_attribute> - <oaf_attribute name="name" type="string" _value="Show Desktop"/> - <oaf_attribute name="description" type="string" _value="Hide application windows and show the desktop"/> -- <oaf_attribute name="panel:icon" type="string" value="gnome-fs-desktop.png"/> -+ <oaf_attribute name="panel:icon" type="string" value="user-desktop.png"/> - <oaf_attribute name="bugzilla:bugzilla" type="string" value="GNOME"/> - <oaf_attribute name="bugzilla:product" type="string" value="gnome-panel"/> - <oaf_attribute name="bugzilla:component" type="string" value="Show Desktop Button"/> -diff -up gnome-panel-2.23.4/gnome-panel/panel-icon-names.h.icon-names gnome-panel-2.23.4/gnome-panel/panel-icon-names.h ---- gnome-panel-2.23.4/gnome-panel/panel-icon-names.h.icon-names 2008-06-17 06:02:08.000000000 -0400 -+++ gnome-panel-2.23.4/gnome-panel/panel-icon-names.h 2008-07-18 21:53:39.000000000 -0400 -@@ -25,7 +25,7 @@ - #define PANEL_ICON_SEPARATOR "gnome-panel-separator" - #define PANEL_ICON_SAVED_SEARCH "folder-saved-search" - #define PANEL_ICON_SEARCHTOOL "system-search" --#define PANEL_ICON_SHUTDOWN "gnome-shutdown" -+#define PANEL_ICON_SHUTDOWN "system-shutdown" - #define PANEL_ICON_THEME "preferences-desktop-theme" - #define PANEL_ICON_TRASH "user-trash" - #define PANEL_ICON_UNKNOWN "image-missing" diff --git a/preferred-apps.patch b/preferred-apps.patch index 831b983..71281e2 100644 --- a/preferred-apps.patch +++ b/preferred-apps.patch @@ -1,15 +1,15 @@ -diff -up gnome-panel-2.23.5/gnome-panel/launcher.c.preferred-apps gnome-panel-2.23.5/gnome-panel/launcher.c ---- gnome-panel-2.23.5/gnome-panel/launcher.c.preferred-apps 2008-07-22 22:20:48.000000000 -0400 -+++ gnome-panel-2.23.5/gnome-panel/launcher.c 2008-07-22 22:36:59.000000000 -0400 -@@ -23,6 +23,7 @@ +diff -up gnome-panel-2.23.6/gnome-panel/launcher.c.preferred-apps gnome-panel-2.23.6/gnome-panel/launcher.c +--- gnome-panel-2.23.6/gnome-panel/launcher.c.preferred-apps 2008-08-05 12:31:49.000000000 -0400 ++++ gnome-panel-2.23.6/gnome-panel/launcher.c 2008-08-05 12:35:46.000000000 -0400 +@@ -22,6 +22,7 @@ + #include <gio/gio.h> #include <libgnome/gnome-util.h> - #include <libgnomeui/gnome-url.h> #include <gdk/gdkx.h> +#include <gmenu-tree.h> + #include <libpanel-util/panel-error.h> #include <libpanel-util/panel-glib.h> - #include <libpanel-util/panel-keyfile.h> -@@ -43,6 +44,7 @@ +@@ -44,6 +45,7 @@ #include "panel-compatibility.h" #include "panel-ditem-editor.h" #include "panel-icon-names.h" @@ -17,7 +17,7 @@ diff -up gnome-panel-2.23.5/gnome-panel/launcher.c.preferred-apps gnome-panel-2. static GdkScreen * launcher_get_screen (Launcher *launcher) -@@ -1300,3 +1302,173 @@ panel_launcher_set_dnd_enabled (Launcher +@@ -1282,3 +1284,173 @@ panel_launcher_set_dnd_enabled (Launcher } else gtk_drag_source_unset (launcher->button); } @@ -191,9 +191,9 @@ diff -up gnome-panel-2.23.5/gnome-panel/launcher.c.preferred-apps gnome-panel-2. + filename, g_free, NULL); + } +} -diff -up gnome-panel-2.23.5/gnome-panel/launcher.h.preferred-apps gnome-panel-2.23.5/gnome-panel/launcher.h ---- gnome-panel-2.23.5/gnome-panel/launcher.h.preferred-apps 2008-07-22 22:20:48.000000000 -0400 -+++ gnome-panel-2.23.5/gnome-panel/launcher.h 2008-07-22 22:20:49.000000000 -0400 +diff -up gnome-panel-2.23.6/gnome-panel/launcher.h.preferred-apps gnome-panel-2.23.6/gnome-panel/launcher.h +--- gnome-panel-2.23.6/gnome-panel/launcher.h.preferred-apps 2008-08-05 12:31:49.000000000 -0400 ++++ gnome-panel-2.23.6/gnome-panel/launcher.h 2008-08-05 12:31:49.000000000 -0400 @@ -14,6 +14,8 @@ #include "applet.h" #include "panel-widget.h" @@ -211,9 +211,9 @@ diff -up gnome-panel-2.23.5/gnome-panel/launcher.h.preferred-apps gnome-panel-2. G_END_DECLS -diff -up gnome-panel-2.23.5/gnome-panel/main.c.preferred-apps gnome-panel-2.23.5/gnome-panel/main.c ---- gnome-panel-2.23.5/gnome-panel/main.c.preferred-apps 2008-07-22 17:50:58.000000000 -0400 -+++ gnome-panel-2.23.5/gnome-panel/main.c 2008-07-22 22:20:49.000000000 -0400 +diff -up gnome-panel-2.23.6/gnome-panel/main.c.preferred-apps gnome-panel-2.23.6/gnome-panel/main.c +--- gnome-panel-2.23.6/gnome-panel/main.c.preferred-apps 2008-08-04 16:43:10.000000000 -0400 ++++ gnome-panel-2.23.6/gnome-panel/main.c 2008-08-05 12:31:49.000000000 -0400 @@ -28,6 +28,7 @@ #include "panel-action-protocol.h" #include "panel-lockdown.h" @@ -230,10 +230,10 @@ diff -up gnome-panel-2.23.5/gnome-panel/main.c.preferred-apps gnome-panel-2.23.5 panel_global_config_load (); panel_lockdown_init (); panel_profile_load (); -diff -up gnome-panel-2.23.5/gnome-panel/panel-run-dialog.c.preferred-apps gnome-panel-2.23.5/gnome-panel/panel-run-dialog.c ---- gnome-panel-2.23.5/gnome-panel/panel-run-dialog.c.preferred-apps 2008-07-22 17:50:58.000000000 -0400 -+++ gnome-panel-2.23.5/gnome-panel/panel-run-dialog.c 2008-07-22 22:20:49.000000000 -0400 -@@ -818,7 +818,7 @@ get_all_applications_from_dir (GMenuTree +diff -up gnome-panel-2.23.6/gnome-panel/panel-run-dialog.c.preferred-apps gnome-panel-2.23.6/gnome-panel/panel-run-dialog.c +--- gnome-panel-2.23.6/gnome-panel/panel-run-dialog.c.preferred-apps 2008-08-04 16:43:10.000000000 -0400 ++++ gnome-panel-2.23.6/gnome-panel/panel-run-dialog.c 2008-08-05 12:31:49.000000000 -0400 +@@ -797,7 +797,7 @@ get_all_applications_from_dir (GMenuTree return list; } @@ -242,9 +242,9 @@ diff -up gnome-panel-2.23.5/gnome-panel/panel-run-dialog.c.preferred-apps gnome- get_all_applications (void) { GMenuTree *tree; -diff -up gnome-panel-2.23.5/gnome-panel/panel-run-dialog.h.preferred-apps gnome-panel-2.23.5/gnome-panel/panel-run-dialog.h ---- gnome-panel-2.23.5/gnome-panel/panel-run-dialog.h.preferred-apps 2008-07-22 17:50:58.000000000 -0400 -+++ gnome-panel-2.23.5/gnome-panel/panel-run-dialog.h 2008-07-22 22:20:49.000000000 -0400 +diff -up gnome-panel-2.23.6/gnome-panel/panel-run-dialog.h.preferred-apps gnome-panel-2.23.6/gnome-panel/panel-run-dialog.h +--- gnome-panel-2.23.6/gnome-panel/panel-run-dialog.h.preferred-apps 2008-08-04 16:43:10.000000000 -0400 ++++ gnome-panel-2.23.6/gnome-panel/panel-run-dialog.h 2008-08-05 12:31:49.000000000 -0400 @@ -32,6 +32,8 @@ G_BEGIN_DECLS void panel_run_dialog_present (GdkScreen *screen, guint32 activate_time); @@ -1 +1 @@ -075172fb7a72e8a35df50e99a5a826af gnome-panel-2.23.5.tar.bz2 +6204b45029b79deeb6b05e46b7c2908d gnome-panel-2.23.6.tar.bz2 diff --git a/timezone-debug.patch b/timezone-debug.patch deleted file mode 100644 index 39d4735..0000000 --- a/timezone-debug.patch +++ /dev/null @@ -1,12 +0,0 @@ -diff -up gnome-panel-2.22.1.2/applets/clock/system-timezone.c.timezone-debug gnome-panel-2.22.1.2/applets/clock/system-timezone.c ---- gnome-panel-2.22.1.2/applets/clock/system-timezone.c.timezone-debug 2008-04-22 20:17:15.000000000 -0400 -+++ gnome-panel-2.22.1.2/applets/clock/system-timezone.c 2008-04-23 10:05:34.000000000 -0400 -@@ -863,7 +863,7 @@ system_timezone_is_zone_file_valid (cons - return FALSE; - } - -- if (read != 4 || strcmp (buffer, TZ_MAGIC) != 0) { -+ if (read != strlen (TZ_MAGIC) || strncmp (buffer, TZ_MAGIC, strlen (TZ_MAGIC)) != 0) { - g_set_error (error, SYSTEM_TIMEZONE_ERROR, - SYSTEM_TIMEZONE_ERROR_INVALID_TIMEZONE_FILE, - "%s is not a timezone file", |