Add a patch from upstream to fix the updates plugin.
This commit is contained in:
parent
f76b0323d8
commit
bc927754ee
64
gnome-settings-daemon-2.91.91-fix-updates-plugin.patch
Normal file
64
gnome-settings-daemon-2.91.91-fix-updates-plugin.patch
Normal file
@ -0,0 +1,64 @@
|
|||||||
|
diff --git a/plugins/updates/gsd-updates-manager.c b/plugins/updates/gsd-updates-manager.c
|
||||||
|
index d869712..64373bd 100644
|
||||||
|
--- a/plugins/updates/gsd-updates-manager.c
|
||||||
|
+++ b/plugins/updates/gsd-updates-manager.c
|
||||||
|
@@ -350,15 +350,16 @@ notify_normal_updates_maybe (GsdUpdatesManager *manager, GPtrArray *array)
|
||||||
|
NotifyNotification *notification;
|
||||||
|
|
||||||
|
/* find out if enough time has passed since the last notification */
|
||||||
|
- time_now = g_get_real_time ();
|
||||||
|
+ time_now = g_get_real_time () / 1000000;
|
||||||
|
freq_updates_notify = g_settings_get_int (manager->priv->settings_gsd,
|
||||||
|
GSD_SETTINGS_FREQUENCY_UPDATES_NOTIFICATION);
|
||||||
|
g_settings_get (manager->priv->settings_gsd,
|
||||||
|
GSD_SETTINGS_LAST_UPDATES_NOTIFICATION,
|
||||||
|
"t", &time_last_notify);
|
||||||
|
- if ((guint64) freq_updates_notify < time_now - time_last_notify) {
|
||||||
|
- g_debug ("not showing non-critical notification as already shown %i days ago",
|
||||||
|
- (guint) (time_now - time_last_notify) / (24 * 60 * 60));
|
||||||
|
+ if (time_last_notify > 0 &&
|
||||||
|
+ (guint64) freq_updates_notify > time_now - time_last_notify) {
|
||||||
|
+ g_debug ("not showing non-critical notification as already shown %i hours ago",
|
||||||
|
+ (guint) (time_now - time_last_notify) / (60 * 60));
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
@@ -835,6 +836,7 @@ get_updates_finished_cb (GObject *object,
|
||||||
|
if (update == GSD_UPDATE_TYPE_SECURITY) {
|
||||||
|
if (security_array->len == 0) {
|
||||||
|
g_debug ("policy security, but none available");
|
||||||
|
+ notify_normal_updates_maybe (manager, array);
|
||||||
|
goto out;
|
||||||
|
}
|
||||||
|
|
||||||
|
@@ -1405,7 +1407,7 @@ gsd_updates_manager_start (GsdUpdatesManager *manager,
|
||||||
|
set_install_root (manager);
|
||||||
|
|
||||||
|
/* load introspection from file */
|
||||||
|
- file = g_file_new_for_path (DATADIR "/dbus-1/interfaces/org.gnome.ColorManager.xml");
|
||||||
|
+ file = g_file_new_for_path (DATADIR "/dbus-1/interfaces/org.gnome.SettingsDaemonUpdates.xml");
|
||||||
|
ret = g_file_load_contents (file, NULL, &introspection_data, NULL, NULL, error);
|
||||||
|
if (!ret)
|
||||||
|
goto out;
|
||||||
|
diff --git a/plugins/updates/gsd-updates-refresh.c b/plugins/updates/gsd-updates-refresh.c
|
||||||
|
index 9193358..15e6917 100644
|
||||||
|
--- a/plugins/updates/gsd-updates-refresh.c
|
||||||
|
+++ b/plugins/updates/gsd-updates-refresh.c
|
||||||
|
@@ -506,7 +506,7 @@ session_presence_signal_cb (GDBusProxy *proxy,
|
||||||
|
if (g_strcmp0 (signal_name, "StatusChanged") != 0)
|
||||||
|
return;
|
||||||
|
|
||||||
|
- /* map stauts code into boolean */
|
||||||
|
+ /* map status code into boolean */
|
||||||
|
g_variant_get (parameters, "(u)", &status);
|
||||||
|
refresh->priv->session_idle = (status == PRESENCE_STATUS_IDLE);
|
||||||
|
g_debug ("setting is_idle %i",
|
||||||
|
@@ -578,7 +578,7 @@ gsd_updates_refresh_init (GsdUpdatesRefresh *refresh)
|
||||||
|
refresh);
|
||||||
|
status = g_dbus_proxy_get_cached_property (refresh->priv->proxy_session,
|
||||||
|
"status");
|
||||||
|
- g_variant_get (status, "(u)", &status_code);
|
||||||
|
+ g_variant_get (status, "u", &status_code);
|
||||||
|
refresh->priv->session_idle = (status_code == PRESENCE_STATUS_IDLE);
|
||||||
|
g_variant_unref (status);
|
||||||
|
}
|
@ -1,6 +1,6 @@
|
|||||||
Name: gnome-settings-daemon
|
Name: gnome-settings-daemon
|
||||||
Version: 2.91.91
|
Version: 2.91.91
|
||||||
Release: 2%{?dist}
|
Release: 3%{?dist}
|
||||||
Summary: The daemon sharing settings from GNOME to GTK+/KDE applications
|
Summary: The daemon sharing settings from GNOME to GTK+/KDE applications
|
||||||
|
|
||||||
Group: System Environment/Daemons
|
Group: System Environment/Daemons
|
||||||
@ -9,6 +9,9 @@ URL: http://download.gnome.org/sources/%{name}
|
|||||||
#VCS: git:git://git.gnome.org/gnome-settings-daemon
|
#VCS: git:git://git.gnome.org/gnome-settings-daemon
|
||||||
Source: http://download.gnome.org/sources/%{name}/2.91/%{name}-%{version}.tar.bz2
|
Source: http://download.gnome.org/sources/%{name}/2.91/%{name}-%{version}.tar.bz2
|
||||||
|
|
||||||
|
# Already upstream
|
||||||
|
Patch0: gnome-settings-daemon-2.91.91-fix-updates-plugin.patch
|
||||||
|
|
||||||
Requires(pre): GConf2 >= 2.14
|
Requires(pre): GConf2 >= 2.14
|
||||||
Requires(preun): GConf2 >= 2.14
|
Requires(preun): GConf2 >= 2.14
|
||||||
Requires(post): GConf2 >= 2.14
|
Requires(post): GConf2 >= 2.14
|
||||||
@ -54,6 +57,7 @@ developing applications that use %{name}.
|
|||||||
|
|
||||||
%prep
|
%prep
|
||||||
%setup -q
|
%setup -q
|
||||||
|
%patch0 -p1 -b .fix-updates
|
||||||
|
|
||||||
autoreconf -i -f
|
autoreconf -i -f
|
||||||
|
|
||||||
@ -189,6 +193,9 @@ gtk-update-icon-cache %{_datadir}/icons/hicolor >&/dev/null || :
|
|||||||
%{_libdir}/pkgconfig/gnome-settings-daemon.pc
|
%{_libdir}/pkgconfig/gnome-settings-daemon.pc
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Wed Mar 16 2011 Richard Hughes <rhughes@redhat.com> 2.91.91-3
|
||||||
|
- Add a patch from upstream to fix the updates plugin.
|
||||||
|
|
||||||
* Fri Mar 11 2011 Bastien Nocera <bnocera@redhat.com> 2.91.91-2
|
* Fri Mar 11 2011 Bastien Nocera <bnocera@redhat.com> 2.91.91-2
|
||||||
- Add libXxf86misc-devel requires so that key repeat/delay works
|
- Add libXxf86misc-devel requires so that key repeat/delay works
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user