From 11dde98d761efc2e997ab2e6671ab362cf376471 Mon Sep 17 00:00:00 2001 From: Matthias Clasen Date: Apr 05 2010 15:48:01 +0000 Subject: fix icon handling --- diff --git a/0001-Always-emit-changed-signal-when-setting-user-photo.patch b/0001-Always-emit-changed-signal-when-setting-user-photo.patch new file mode 100644 index 0000000..a244e3d --- /dev/null +++ b/0001-Always-emit-changed-signal-when-setting-user-photo.patch @@ -0,0 +1,41 @@ +From e62a19357e8e3866d7ca07fdd128d8163765a80a Mon Sep 17 00:00:00 2001 +From: Matthias Clasen +Date: Mon, 5 Apr 2010 11:32:26 -0400 +Subject: [PATCH] Always emit changed signal when setting user photo + +With the new copying approach, we can't rely on the path to change... +--- + src/user.c | 14 +++++--------- + 1 files changed, 5 insertions(+), 9 deletions(-) + +diff --git a/src/user.c b/src/user.c +index 0eb3232..72ecd22 100644 +--- a/src/user.c ++++ b/src/user.c +@@ -1353,18 +1353,14 @@ user_change_icon_file_authorized_cb (Daemon *daemon, + filename = dest_path; + } + +- if (g_strcmp0 (user->icon_file, filename) != 0) { +- g_free (user->icon_file); +- user->icon_file = g_strdup (filename); +- +- save_extra_data (user); ++ g_free (user->icon_file); ++ user->icon_file = filename; + +- g_signal_emit (user, signals[CHANGED], 0); ++ save_extra_data (user); + +- g_object_notify (G_OBJECT (user), "icon-file"); +- } ++ g_signal_emit (user, signals[CHANGED], 0); + +- g_free (filename); ++ g_object_notify (G_OBJECT (user), "icon-file"); + + dbus_g_method_return (context); + } +-- +1.7.0.1 + diff --git a/accountsservice.spec b/accountsservice.spec index 2942d93..97da7b6 100644 --- a/accountsservice.spec +++ b/accountsservice.spec @@ -1,7 +1,7 @@ Name: accountsservice Version: 0.6 -Release: 1%{?dist} +Release: 2%{?dist} Summary: D-Bus interfaces for querying and manipulating user account information Group: System Environment/Daemons @@ -10,6 +10,8 @@ URL: http://www.fedoraproject.org/wiki/Features/UserAccountDialog #VCS: git:git://git.freedesktop.org/accountsservice Source0: http://mclasen.fedorapeople.org/accounts/accountsservice-0.6.tar.bz2 +# upstream fix +Patch0: 0001-Always-emit-changed-signal-when-setting-user-photo.patch BuildRequires: glib2-devel BuildRequires: dbus-glib-devel BuildRequires: polkit-devel @@ -26,6 +28,7 @@ of these interfaces, based on the useradd, usermod and userdel commands. %prep %setup -q +%patch0 -p1 -b .icon-change %build %configure @@ -56,6 +59,9 @@ rm -rf $RPM_BUILD_ROOT %changelog +* Mon Apr 5 2010 Matthias Clasen 0.6-2 +- Always emit changed signal on icon change + * Tue Mar 30 2010 Matthias Clasen 0.6-1 - Update to 0.6