r35060 - in /desktop/experimental/gnome-shell/debian: changelog patches/21_revert_evolution_gsettings.patch patches/series
biebl at users.alioth.debian.org
biebl at users.alioth.debian.org
Sat May 19 15:12:54 UTC 2012
Author: biebl
Date: Sat May 19 15:12:54 2012
New Revision: 35060
URL: http://svn.debian.org/wsvn/pkg-gnome/?sc=1&rev=35060
Log:
debian/patches/21_revert_evolution_gsettings.patch: Revert the switch to
gsettings in the calendar server for now as long as evolution 3.4 is not
ready yet.
Added:
desktop/experimental/gnome-shell/debian/patches/21_revert_evolution_gsettings.patch
Modified:
desktop/experimental/gnome-shell/debian/changelog
desktop/experimental/gnome-shell/debian/patches/series
Modified: desktop/experimental/gnome-shell/debian/changelog
URL: http://svn.debian.org/wsvn/pkg-gnome/desktop/experimental/gnome-shell/debian/changelog?rev=35060&op=diff
==============================================================================
--- desktop/experimental/gnome-shell/debian/changelog [utf-8] (original)
+++ desktop/experimental/gnome-shell/debian/changelog [utf-8] Sat May 19 15:12:54 2012
@@ -22,6 +22,9 @@
[ Michael Biebl ]
* debian/patches/10-make-NetworkManager-optional.patch: Updated.
* debian/gnome-shell-common.install: Install GConf conversion script.
+ * debian/patches/21_revert_evolution_gsettings.patch: Revert the switch to
+ gsettings in the calendar server for now as long as evolution 3.4 is not
+ ready yet.
-- Sjoerd Simons <sjoerd at debian.org> Sat, 19 May 2012 00:30:19 +0200
Added: desktop/experimental/gnome-shell/debian/patches/21_revert_evolution_gsettings.patch
URL: http://svn.debian.org/wsvn/pkg-gnome/desktop/experimental/gnome-shell/debian/patches/21_revert_evolution_gsettings.patch?rev=35060&op=file
==============================================================================
--- desktop/experimental/gnome-shell/debian/patches/21_revert_evolution_gsettings.patch (added)
+++ desktop/experimental/gnome-shell/debian/patches/21_revert_evolution_gsettings.patch [utf-8] Sat May 19 15:12:54 2012
@@ -1,0 +1,259 @@
+Index: gnome-shell-3.4.1/src/calendar-server/calendar-sources.c
+===================================================================
+--- gnome-shell-3.4.1.orig/src/calendar-server/calendar-sources.c 2012-04-16 12:41:48.000000000 -0400
++++ gnome-shell-3.4.1/src/calendar-server/calendar-sources.c 2012-04-17 19:21:27.524564190 -0400
+@@ -50,11 +50,11 @@
+
+ #define CALENDAR_SOURCES_EVO_DIR "/apps/evolution"
+ #define CALENDAR_SOURCES_APPOINTMENT_SOURCES_KEY CALENDAR_SOURCES_EVO_DIR "/calendar/sources"
++#define CALENDAR_SOURCES_SELECTED_APPOINTMENT_SOURCES_DIR CALENDAR_SOURCES_EVO_DIR "/calendar/display"
++#define CALENDAR_SOURCES_SELECTED_APPOINTMENT_SOURCES_KEY CALENDAR_SOURCES_SELECTED_APPOINTMENT_SOURCES_DIR "/selected_calendars"
+ #define CALENDAR_SOURCES_TASK_SOURCES_KEY CALENDAR_SOURCES_EVO_DIR "/tasks/sources"
+-
+-#define CALENDAR_SELECTED_SOURCES_SCHEMA "org.gnome.evolution.calendar"
+-#define CALENDAR_SOURCES_SELECTED_APPOINTMENT_SOURCES_KEY "selected-calendars"
+-#define CALENDAR_SOURCES_SELECTED_TASK_SOURCES_KEY "selected-tasks"
++#define CALENDAR_SOURCES_SELECTED_TASK_SOURCES_DIR CALENDAR_SOURCES_EVO_DIR "/calendar/tasks"
++#define CALENDAR_SOURCES_SELECTED_TASK_SOURCES_KEY CALENDAR_SOURCES_SELECTED_TASK_SOURCES_DIR "/selected_tasks"
+
+ typedef struct _CalendarSourceData CalendarSourceData;
+
+@@ -65,10 +65,11 @@
+ guint changed_signal;
+
+ GSList *clients;
+- char **selected_sources;
++ GSList *selected_sources;
+ ESourceList *esource_list;
+
+- guint selected_sources_handler_id;
++ guint selected_sources_listener;
++ char *selected_sources_dir;
+
+ guint timeout_id;
+
+@@ -81,7 +82,6 @@
+ CalendarSourceData task_sources;
+
+ GConfClient *gconf_client;
+- GSettings *settings;
+ };
+
+ static void calendar_sources_class_init (CalendarSourcesClass *klass);
+@@ -183,7 +183,6 @@
+ sources->priv->task_sources.timeout_id = 0;
+
+ sources->priv->gconf_client = gconf_client_get_default ();
+- sources->priv->settings = g_settings_new (CALENDAR_SELECTED_SOURCES_SCHEMA);
+ }
+
+ static void
+@@ -194,11 +193,21 @@
+ {
+ GSList *l;
+
+- if (source_data->selected_sources_handler_id)
++ if (source_data->selected_sources_dir)
++ {
++ gconf_client_remove_dir (sources->priv->gconf_client,
++ source_data->selected_sources_dir,
++ NULL);
++
++ g_free (source_data->selected_sources_dir);
++ source_data->selected_sources_dir = NULL;
++ }
++
++ if (source_data->selected_sources_listener)
+ {
+- g_signal_handler_disconnect (sources->priv->settings,
+- source_data->selected_sources_handler_id);
+- source_data->selected_sources_handler_id = 0;
++ gconf_client_notify_remove (sources->priv->gconf_client,
++ source_data->selected_sources_listener);
++ source_data->selected_sources_listener = 0;
+ }
+
+ for (l = source_data->clients; l; l = l->next)
+@@ -220,7 +229,9 @@
+ }
+ source_data->esource_list = NULL;
+
+- g_strfreev (source_data->selected_sources);
++ for (l = source_data->selected_sources; l; l = l->next)
++ g_free (l->data);
++ g_slist_free (source_data->selected_sources);
+ source_data->selected_sources = NULL;
+
+ if (source_data->timeout_id != 0)
+@@ -245,10 +256,6 @@
+ g_object_unref (sources->priv->gconf_client);
+ sources->priv->gconf_client = NULL;
+
+- if (sources->priv->settings)
+- g_object_unref (sources->priv->settings);
+- sources->priv->settings = NULL;
+-
+ if (G_OBJECT_CLASS (parent_class)->finalize)
+ G_OBJECT_CLASS (parent_class)->finalize (object);
+ }
+@@ -270,16 +277,18 @@
+
+ static gboolean
+ is_source_selected (ESource *esource,
+- char **selected_sources)
++ GSList *selected_sources)
+ {
+ const char *uid;
+- char **source;
++ GSList *l;
+
+ uid = e_source_peek_uid (esource);
+
+- for (source = selected_sources; *source; source++)
++ for (l = selected_sources; l; l = l->next)
+ {
+- if (!strcmp (*source, uid))
++ const char *source = l->data;
++
++ if (!strcmp (source, uid))
+ return TRUE;
+ }
+
+@@ -352,15 +361,17 @@
+ }
+
+ static inline void
+-debug_dump_selected_sources (char **selected_sources)
++debug_dump_selected_sources (GSList *selected_sources)
+ {
+ #ifdef CALENDAR_ENABLE_DEBUG
+- char **source;
++ GSList *l;
+
+ dprintf ("Selected sources:\n");
+- for (source = selected_sources; *source; source++)
++ for (l = selected_sources; l; l = l->next)
+ {
+- dprintf (" %s\n", *source);
++ char *source = l->data;
++
++ dprintf (" %s\n", source);
+ }
+ dprintf ("\n");
+ #endif
+@@ -511,14 +522,34 @@
+ }
+
+ static void
+-calendar_sources_selected_sources_notify (GSettings *settings,
+- const gchar *key,
++calendar_sources_selected_sources_notify (GConfClient *client,
++ guint cnx_id,
++ GConfEntry *entry,
+ CalendarSourceData *source_data)
+ {
+- dprintf ("Selected sources key (%s) changed, reloading\n", key);
++ GSList *l;
+
+- g_strfreev (source_data->selected_sources);
+- source_data->selected_sources = g_settings_get_strv (settings, key);
++ if (!entry->value ||
++ entry->value->type != GCONF_VALUE_LIST ||
++ gconf_value_get_list_type (entry->value) != GCONF_VALUE_STRING)
++ return;
++
++ dprintf ("Selected sources key (%s) changed, reloading\n", entry->key);
++
++ for (l = source_data->selected_sources; l; l = l->next)
++ g_free (l->data);
++ source_data->selected_sources = NULL;
++
++ for (l = gconf_value_get_list (entry->value); l; l = l->next)
++ {
++ const char *source = gconf_value_get_string (l->data);
++
++ source_data->selected_sources =
++ g_slist_prepend (source_data->selected_sources,
++ g_strdup (source));
++ }
++ source_data->selected_sources =
++ g_slist_reverse (source_data->selected_sources);
+
+ calendar_sources_load_esource_list (source_data);
+ }
+@@ -527,27 +558,45 @@
+ calendar_sources_load_sources (CalendarSources *sources,
+ CalendarSourceData *source_data,
+ const char *sources_key,
+- const char *selected_sources_key)
++ const char *selected_sources_key,
++ const char *selected_sources_dir)
+ {
+ GConfClient *gconf_client;
+- GSettings *settings;
+- char *signal_name;
++ GError *error;
+
+ dprintf ("---------------------------\n");
+ dprintf ("Loading sources:\n");
+ dprintf (" sources_key: %s\n", sources_key);
+ dprintf (" selected_sources_key: %s\n", selected_sources_key);
++ dprintf (" selected_sources_dir: %s\n", selected_sources_dir);
+
+ gconf_client = sources->priv->gconf_client;
+- settings = sources->priv->settings;
+
+- source_data->selected_sources = g_settings_get_strv (settings, selected_sources_key);
++ error = NULL;
++ source_data->selected_sources = gconf_client_get_list (gconf_client,
++ selected_sources_key,
++ GCONF_VALUE_STRING,
++ &error);
++ if (error)
++ {
++ g_warning ("Failed to get selected sources from '%s': %s\n",
++ selected_sources_key,
++ error->message);
++ g_error_free (error);
++ return;
++ }
+
+- signal_name = g_strconcat ("changed::", selected_sources_key, NULL);
+- source_data->selected_sources_handler_id =
+- g_signal_connect (settings, signal_name,
+- G_CALLBACK (calendar_sources_selected_sources_notify), source_data);
+- g_free (signal_name);
++ gconf_client_add_dir (gconf_client,
++ selected_sources_dir,
++ GCONF_CLIENT_PRELOAD_NONE,
++ NULL);
++ source_data->selected_sources_dir = g_strdup (selected_sources_dir);
++
++ source_data->selected_sources_listener =
++ gconf_client_notify_add (gconf_client,
++ selected_sources_dir,
++ (GConfClientNotifyFunc) calendar_sources_selected_sources_notify,
++ source_data, NULL, NULL);
+
+ source_data->esource_list = e_source_list_new_for_gconf (gconf_client, sources_key);
+ g_signal_connect (source_data->esource_list, "changed",
+@@ -571,7 +620,8 @@
+ calendar_sources_load_sources (sources,
+ &sources->priv->appointment_sources,
+ CALENDAR_SOURCES_APPOINTMENT_SOURCES_KEY,
+- CALENDAR_SOURCES_SELECTED_APPOINTMENT_SOURCES_KEY);
++ CALENDAR_SOURCES_SELECTED_APPOINTMENT_SOURCES_KEY,
++ CALENDAR_SOURCES_SELECTED_APPOINTMENT_SOURCES_DIR);
+ }
+
+ return sources->priv->appointment_sources.clients;
+@@ -587,7 +637,8 @@
+ calendar_sources_load_sources (sources,
+ &sources->priv->task_sources,
+ CALENDAR_SOURCES_TASK_SOURCES_KEY,
+- CALENDAR_SOURCES_SELECTED_TASK_SOURCES_KEY);
++ CALENDAR_SOURCES_SELECTED_TASK_SOURCES_KEY,
++ CALENDAR_SOURCES_SELECTED_TASK_SOURCES_DIR);
+ }
+
+ return sources->priv->task_sources.clients;
Modified: desktop/experimental/gnome-shell/debian/patches/series
URL: http://svn.debian.org/wsvn/pkg-gnome/desktop/experimental/gnome-shell/debian/patches/series?rev=35060&op=diff
==============================================================================
--- desktop/experimental/gnome-shell/debian/patches/series [utf-8] (original)
+++ desktop/experimental/gnome-shell/debian/patches/series [utf-8] Sat May 19 15:12:54 2012
@@ -2,3 +2,4 @@
10-make-NetworkManager-optional.patch
11-no-gettext.patch
14_make-GLX-optional.patch
+21_revert_evolution_gsettings.patch
More information about the pkg-gnome-commits
mailing list