- Fix setting timezones in the date & time panel (#674999)
This commit is contained in:
parent
c1be39230f
commit
181c921466
@ -0,0 +1,28 @@
|
||||
From 967c7a9bb41ecde9293ccfd672f1b7c491e9a268 Mon Sep 17 00:00:00 2001
|
||||
From: Bastien Nocera <hadess@hadess.net>
|
||||
Date: Tue, 8 Feb 2011 23:11:08 +0000
|
||||
Subject: [PATCH] datetime: Fix gsd_datetime_check_tz_name() never working
|
||||
|
||||
Wrong variable passed into g_file_new_for_path()...
|
||||
|
||||
https://bugzilla.redhat.com/show_bug.cgi?id=674999
|
||||
---
|
||||
plugins/datetime/gsd-datetime-mechanism.c | 2 +-
|
||||
1 files changed, 1 insertions(+), 1 deletions(-)
|
||||
|
||||
diff --git a/plugins/datetime/gsd-datetime-mechanism.c b/plugins/datetime/gsd-datetime-mechanism.c
|
||||
index 89f1c66..4f34f0b 100644
|
||||
--- a/plugins/datetime/gsd-datetime-mechanism.c
|
||||
+++ b/plugins/datetime/gsd-datetime-mechanism.c
|
||||
@@ -517,7 +517,7 @@ gsd_datetime_check_tz_name (const char *tz,
|
||||
tz_path = g_build_filename (SYSTEM_ZONEINFODIR, tz, NULL);
|
||||
|
||||
/* Get the actual resolved path */
|
||||
- file = g_file_new_for_path (tz);
|
||||
+ file = g_file_new_for_path (tz_path);
|
||||
actual_path = g_file_get_path (file);
|
||||
g_object_unref (file);
|
||||
|
||||
--
|
||||
1.7.4
|
||||
|
@ -1,65 +0,0 @@
|
||||
From cb9a3a0e4144d4fc550877fea8c4c0518fa6c46b Mon Sep 17 00:00:00 2001
|
||||
From: Owen W. Taylor <otaylor@fishsoup.net>
|
||||
Date: Tue, 30 Nov 2010 22:22:28 -0500
|
||||
Subject: [PATCH] autorun: Handle rename of org.gnome.media-handling
|
||||
|
||||
When the org.gnome.media-handling schemas was moved to
|
||||
gsettings-desktop-schemas, it was renamed to
|
||||
org.gnome.desktop.media-handling.
|
||||
---
|
||||
configure.ac | 2 +-
|
||||
plugins/automount/gsd-automount-manager.c | 2 +-
|
||||
plugins/automount/nautilus-autorun.c | 4 ++--
|
||||
3 files changed, 4 insertions(+), 4 deletions(-)
|
||||
|
||||
diff --git a/configure.ac b/configure.ac
|
||||
index 8b3d004..787714a 100644
|
||||
--- a/configure.ac
|
||||
+++ b/configure.ac
|
||||
@@ -66,7 +66,7 @@ PKG_CHECK_MODULES(SETTINGS_DAEMON,
|
||||
gmodule-2.0
|
||||
gthread-2.0
|
||||
dbus-glib-1 >= $DBUS_GLIB_REQUIRED_VERSION
|
||||
- gsettings-desktop-schemas >= 0.1.1
|
||||
+ gsettings-desktop-schemas >= 0.1.2
|
||||
)
|
||||
|
||||
PKG_CHECK_MODULES(SETTINGS_PLUGIN,
|
||||
diff --git a/plugins/automount/gsd-automount-manager.c b/plugins/automount/gsd-automount-manager.c
|
||||
index d3a7e93..9836dff 100644
|
||||
--- a/plugins/automount/gsd-automount-manager.c
|
||||
+++ b/plugins/automount/gsd-automount-manager.c
|
||||
@@ -217,7 +217,7 @@ gsd_automount_manager_start (GsdAutomountManager *manager,
|
||||
g_debug ("Starting automounting manager");
|
||||
gnome_settings_profile_start (NULL);
|
||||
|
||||
- manager->priv->settings = g_settings_new ("org.gnome.media-handling");
|
||||
+ manager->priv->settings = g_settings_new ("org.gnome.desktop.media-handling");
|
||||
setup_automounter (manager);
|
||||
|
||||
gnome_settings_profile_end (NULL);
|
||||
diff --git a/plugins/automount/nautilus-autorun.c b/plugins/automount/nautilus-autorun.c
|
||||
index eed336d..9d44c53 100644
|
||||
--- a/plugins/automount/nautilus-autorun.c
|
||||
+++ b/plugins/automount/nautilus-autorun.c
|
||||
@@ -196,7 +196,7 @@ nautilus_autorun_get_preferences (const char *x_content_type,
|
||||
g_return_if_fail (pref_ignore != NULL);
|
||||
g_return_if_fail (pref_open_folder != NULL);
|
||||
|
||||
- settings = g_settings_new ("org.gnome.media-handling");
|
||||
+ settings = g_settings_new ("org.gnome.desktop.media-handling");
|
||||
|
||||
*pref_start_app = FALSE;
|
||||
*pref_ignore = FALSE;
|
||||
@@ -277,7 +277,7 @@ nautilus_autorun_set_preferences (const char *x_content_type,
|
||||
|
||||
g_assert (x_content_type != NULL);
|
||||
|
||||
- settings = g_settings_new ("org.gnome.media-handling");
|
||||
+ settings = g_settings_new ("org.gnome.desktop.media-handling");
|
||||
|
||||
x_content_start_app = g_settings_get_strv (settings, "autorun-x-content-start-app");
|
||||
x_content_ignore = g_settings_get_strv (settings, "autorun-x-content-ignore");
|
||||
--
|
||||
1.7.3.2
|
||||
|
@ -1,167 +0,0 @@
|
||||
commit 6cf4514d7813835040484065f93d55abdfc91087
|
||||
Author: Dan Williams <dcbw@redhat.com>
|
||||
Date: Wed Dec 1 11:32:17 2010 -0600
|
||||
|
||||
background: convert to GDBus (and fix delayed background drawing)
|
||||
|
||||
For some reason the signal filter with plain DBus wasn't working
|
||||
correctly, leading to no background when nautilus was for whatever
|
||||
reason not autolaunched, and show-desktop-icons was TRUE. In any
|
||||
case it should be GDBus not libdbus, so port it. That also
|
||||
happens to fix the signal listening issue.
|
||||
|
||||
https://bugzilla.gnome.org/show_bug.cgi?id=636233
|
||||
|
||||
diff --git a/plugins/background/gsd-background-manager.c b/plugins/background/gsd-background-manager.c
|
||||
index 30370fa..071eb85 100644
|
||||
--- a/plugins/background/gsd-background-manager.c
|
||||
+++ b/plugins/background/gsd-background-manager.c
|
||||
@@ -32,10 +32,9 @@
|
||||
|
||||
#include <locale.h>
|
||||
|
||||
-#include <dbus/dbus.h>
|
||||
-
|
||||
#include <glib.h>
|
||||
#include <glib/gi18n.h>
|
||||
+#include <gio/gio.h>
|
||||
#include <gdk/gdk.h>
|
||||
#include <gdk/gdkx.h>
|
||||
|
||||
@@ -54,7 +53,8 @@ struct GsdBackgroundManagerPrivate
|
||||
GnomeBG *bg;
|
||||
guint timeout_id;
|
||||
|
||||
- DBusConnection *dbus_connection;
|
||||
+ GDBusProxy *proxy;
|
||||
+ guint proxy_signal_id;
|
||||
};
|
||||
|
||||
static void gsd_background_manager_class_init (GsdBackgroundManagerClass *klass);
|
||||
@@ -287,53 +287,77 @@ queue_draw_background (GsdBackgroundManager *manager)
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
-static DBusHandlerResult
|
||||
-on_bus_message (DBusConnection *connection,
|
||||
- DBusMessage *message,
|
||||
- void *user_data)
|
||||
+static void
|
||||
+queue_timeout (GsdBackgroundManager *manager)
|
||||
{
|
||||
- GsdBackgroundManager *manager = user_data;
|
||||
-
|
||||
- if (dbus_message_is_signal (message,
|
||||
- "org.gnome.SessionManager",
|
||||
- "SessionRunning")) {
|
||||
- /* If the session finishes then check if nautilus is
|
||||
- * running and if not, set the background.
|
||||
- *
|
||||
- * We wait a few seconds after the session is up
|
||||
- * because nautilus tells the session manager that its
|
||||
- * ready before it sets the background.
|
||||
- */
|
||||
- manager->priv->timeout_id = g_timeout_add_seconds (8,
|
||||
- (GSourceFunc)
|
||||
- queue_draw_background,
|
||||
- manager);
|
||||
- dbus_connection_remove_filter (connection,
|
||||
- on_bus_message,
|
||||
- manager);
|
||||
-
|
||||
- manager->priv->dbus_connection = NULL;
|
||||
- }
|
||||
+ if (manager->priv->timeout_id > 0)
|
||||
+ return;
|
||||
|
||||
- return DBUS_HANDLER_RESULT_NOT_YET_HANDLED;
|
||||
+ /* If the session finishes then check if nautilus is
|
||||
+ * running and if not, set the background.
|
||||
+ *
|
||||
+ * We wait a few seconds after the session is up
|
||||
+ * because nautilus tells the session manager that its
|
||||
+ * ready before it sets the background.
|
||||
+ */
|
||||
+ manager->priv->timeout_id = g_timeout_add_seconds (8,
|
||||
+ (GSourceFunc)
|
||||
+ queue_draw_background,
|
||||
+ manager);
|
||||
}
|
||||
|
||||
static void
|
||||
-draw_background_after_session_loads (GsdBackgroundManager *manager)
|
||||
+disconnect_session_manager_listener (GsdBackgroundManager *manager)
|
||||
{
|
||||
- DBusConnection *connection;
|
||||
+ if (manager->priv->proxy && manager->priv->proxy_signal_id) {
|
||||
+ g_signal_handler_disconnect (manager->priv->proxy,
|
||||
+ manager->priv->proxy_signal_id);
|
||||
+ manager->priv->proxy_signal_id = 0;
|
||||
+ }
|
||||
+}
|
||||
|
||||
- connection = dbus_bus_get (DBUS_BUS_SESSION, NULL);
|
||||
+static void
|
||||
+on_session_manager_signal (GDBusProxy *proxy,
|
||||
+ const gchar *sender_name,
|
||||
+ const gchar *signal_name,
|
||||
+ GVariant *parameters,
|
||||
+ gpointer user_data)
|
||||
+{
|
||||
+ GsdBackgroundManager *manager = GSD_BACKGROUND_MANAGER (user_data);
|
||||
|
||||
- if (connection == NULL) {
|
||||
- return;
|
||||
+ if (g_strcmp0 (signal_name, "SessionRunning") == 0) {
|
||||
+ queue_timeout (manager);
|
||||
+ disconnect_session_manager_listener (manager);
|
||||
}
|
||||
+}
|
||||
|
||||
- if (!dbus_connection_add_filter (connection, on_bus_message, manager, NULL)) {
|
||||
+static void
|
||||
+draw_background_after_session_loads (GsdBackgroundManager *manager)
|
||||
+{
|
||||
+ GError *error = NULL;
|
||||
+ GDBusProxyFlags flags;
|
||||
+
|
||||
+ flags = G_DBUS_PROXY_FLAGS_DO_NOT_LOAD_PROPERTIES |
|
||||
+ G_DBUS_PROXY_FLAGS_DO_NOT_AUTO_START;
|
||||
+ manager->priv->proxy = g_dbus_proxy_new_for_bus_sync (G_BUS_TYPE_SESSION,
|
||||
+ flags,
|
||||
+ NULL, /* GDBusInterfaceInfo */
|
||||
+ "org.gnome.SessionManager",
|
||||
+ "/org/gnome/SessionManager",
|
||||
+ "org.gnome.SessionManager",
|
||||
+ NULL, /* GCancellable */
|
||||
+ &error);
|
||||
+ if (manager->priv->proxy == NULL) {
|
||||
+ g_warning ("Could not listen to session manager: %s",
|
||||
+ error->message);
|
||||
+ g_error_free (error);
|
||||
return;
|
||||
- };
|
||||
+ }
|
||||
|
||||
- manager->priv->dbus_connection = connection;
|
||||
+ manager->priv->proxy_signal_id = g_signal_connect (manager->priv->proxy,
|
||||
+ "g-signal",
|
||||
+ G_CALLBACK (on_session_manager_signal),
|
||||
+ manager);
|
||||
}
|
||||
|
||||
|
||||
@@ -423,10 +447,9 @@ gsd_background_manager_stop (GsdBackgroundManager *manager)
|
||||
|
||||
disconnect_screen_signals (manager);
|
||||
|
||||
- if (manager->priv->dbus_connection != NULL) {
|
||||
- dbus_connection_remove_filter (manager->priv->dbus_connection,
|
||||
- on_bus_message,
|
||||
- manager);
|
||||
+ if (manager->priv->proxy) {
|
||||
+ disconnect_session_manager_listener (manager);
|
||||
+ g_object_unref (manager->priv->proxy);
|
||||
}
|
||||
|
||||
g_signal_handlers_disconnect_by_func (manager->priv->settings,
|
@ -1,41 +0,0 @@
|
||||
From 5f4d6e23c0f1d37b36e3f4fcad2894af49a4dd33 Mon Sep 17 00:00:00 2001
|
||||
From: Owen W. Taylor <otaylor@fishsoup.net>
|
||||
Date: Tue, 30 Nov 2010 23:04:17 -0500
|
||||
Subject: [PATCH] background: draw the background on startup if show-desktop-icons unset
|
||||
|
||||
When show-desktop-icons is not set, we need to call draw_bg() not just
|
||||
setup_bg(). Also remove a duplicate call to gnome_bg_load_from_preferences()
|
||||
which setup_bg already does.
|
||||
|
||||
https://bugzilla.gnome.org/show_bug.cgi?id=636191
|
||||
---
|
||||
plugins/background/gsd-background-manager.c | 6 ++++--
|
||||
1 files changed, 4 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/plugins/background/gsd-background-manager.c b/plugins/background/gsd-background-manager.c
|
||||
index 30370fa..0e96f1e 100644
|
||||
--- a/plugins/background/gsd-background-manager.c
|
||||
+++ b/plugins/background/gsd-background-manager.c
|
||||
@@ -225,9 +225,10 @@ background_changed (GsdBackgroundManager *manager,
|
||||
if (!nautilus_is_running () || !show_desktop_icons) {
|
||||
if (manager->priv->bg == NULL) {
|
||||
setup_bg (manager);
|
||||
+ } else {
|
||||
+ gnome_bg_load_from_preferences (manager->priv->bg,
|
||||
+ manager->priv->settings);
|
||||
}
|
||||
- gnome_bg_load_from_preferences (manager->priv->bg,
|
||||
- manager->priv->settings);
|
||||
draw_background (manager, use_crossfade);
|
||||
}
|
||||
}
|
||||
@@ -403,6 +404,7 @@ gsd_background_manager_start (GsdBackgroundManager *manager,
|
||||
|
||||
if (!show_desktop_icons) {
|
||||
setup_bg (manager);
|
||||
+ draw_background (manager, FALSE);
|
||||
} else {
|
||||
draw_background_after_session_loads (manager);
|
||||
}
|
||||
--
|
||||
1.7.3.2
|
@ -1,6 +1,6 @@
|
||||
Name: gnome-settings-daemon
|
||||
Version: 2.91.9
|
||||
Release: 1%{?dist}
|
||||
Release: 2%{?dist}
|
||||
Summary: The daemon sharing settings from GNOME to GTK+/KDE applications
|
||||
|
||||
Group: System Environment/Daemons
|
||||
@ -35,6 +35,7 @@ BuildRequires: autoconf automake libtool
|
||||
BuildRequires: libxklavier-devel
|
||||
BuildRequires: gsettings-desktop-schemas-devel >= 0.1.2
|
||||
|
||||
Patch0: 0001-datetime-Fix-gsd_datetime_check_tz_name-never-workin.patch
|
||||
# change font rendering
|
||||
#Patch3: slight-hinting.patch
|
||||
|
||||
@ -54,6 +55,7 @@ developing applications that use %{name}.
|
||||
|
||||
%prep
|
||||
%setup -q
|
||||
%patch0 -p1 -b .tz-setting
|
||||
#%patch3 -p1 -b .slight-hinting
|
||||
|
||||
%build
|
||||
@ -119,6 +121,9 @@ gtk-update-icon-cache %{_datadir}/icons/hicolor >&/dev/null || :
|
||||
%{_libdir}/pkgconfig/gnome-settings-daemon.pc
|
||||
|
||||
%changelog
|
||||
* Tue Feb 08 2011 Bastien Nocera <bnocera@redhat.com> 2.91.9-2
|
||||
- Fix setting timezones in the date & time panel (#674999)
|
||||
|
||||
* Wed Feb 2 2011 Matthias Clasen <mclasen@redhat.com> 2.91.9-1
|
||||
- 2.91.9
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user