Merge lp:~jbicha/indicator-session/add-user-accounts-link into lp:indicator-session/0.1

Proposed by Jeremy Bícha
Status: Merged
Merged at revision: 182
Proposed branch: lp:~jbicha/indicator-session/add-user-accounts-link
Merge into: lp:indicator-session/0.1
Diff against target: 49 lines (+31/-1)
1 file modified
src/user-menu-mgr.c (+31/-1)
To merge this branch: bzr merge lp:~jbicha/indicator-session/add-user-accounts-link
Reviewer Review Type Date Requested Status
Matthew Paul Thomas (community) design Approve
Indicator Applet Developers Pending
Review via email: mp+70619@code.launchpad.net

Description of the change

Originally proposed at https://lists.launchpad.net/ayatana/msg06235.html

I see this option as being far more useful than Online Accounts as users want to be able to change their password, profile picture, automatic login setting, and add an extra user easily.

To post a comment you must log in.
169. By Conor Curran

merged the lightdb dbus changes and the apt restartrequired awareness

170. By Conor Curran

merge the gudev work

171. By Conor Curran

printer support corrected

172. By Conor Curran

add the new greeter mode

173. By Conor Curran

updated the ignores

174. By Conor Curran

restart fix

175. By Conor Curran

bumped for new release

176. By Conor Curran

updates item fix and restart awareness plus correct icons

177. By Conor Curran

merge in the big fix branch

178. By Conor Curran

Ellipses fixes

Revision history for this message
Matthew Paul Thomas (mpt) wrote :

Good idea. I've updated the specification to match.
<https://wiki.ubuntu.com/DeviceMenuAndUserMenu?action=diff&rev2=9&rev1=8>

review: Approve (design)
179. By Jeremy Bícha

Add User Accounts link to bottom of user menu

Revision history for this message
Jeremy Bícha (jbicha) wrote :

Thanks mpt. I've updated my patch to current trunk.

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'src/user-menu-mgr.c'
2--- src/user-menu-mgr.c 2011-08-18 15:21:02 +0000
3+++ src/user-menu-mgr.c 2011-08-21 20:46:24 +0000
4@@ -273,7 +273,24 @@
5 G_CALLBACK (activate_online_accounts),
6 NULL);
7
8- dbusmenu_menuitem_child_append (self->root_item, online_accounts_item);
9+ dbusmenu_menuitem_child_append (self->root_item, online_accounts_item);
10+
11+ DbusmenuMenuitem * user_accounts_item = dbusmenu_menuitem_new();
12+ dbusmenu_menuitem_property_set (user_accounts_item,
13+ DBUSMENU_MENUITEM_PROP_TYPE,
14+ DBUSMENU_CLIENT_TYPES_DEFAULT);
15+ dbusmenu_menuitem_property_set (user_accounts_item,
16+ DBUSMENU_MENUITEM_PROP_LABEL,
17+ _("User Accounts…"));
18+
19+ g_signal_connect (G_OBJECT (user_accounts_item),
20+ DBUSMENU_MENUITEM_SIGNAL_ITEM_ACTIVATED,
21+ G_CALLBACK (activate_user_accounts),
22+ NULL);
23+
24+ dbusmenu_menuitem_child_append (self->root_item, user_accounts_item);
25+
26+
27 }
28
29 /* Checks to see if we can create sessions */
30@@ -357,6 +374,19 @@
31 }
32 }
33
34+static void
35+activate_user_accounts (DbusmenuMenuitem *mi,
36+ guint timestamp,
37+ gpointer user_data)
38+{
39+ GError * error = NULL;
40+ if (!g_spawn_command_line_async("gnome-control-center user-accounts", &error))
41+ {
42+ g_warning("Unable to show control centre: %s", error->message);
43+ g_error_free(error);
44+ }
45+}
46+
47 /* Signal called when a user is added. It updates the count and
48 rebuilds the menu */
49 static void

Subscribers

People subscribed via source and target branches