aboutsummaryrefslogtreecommitdiff
path: root/src/user-menu-mgr.c
diff options
context:
space:
mode:
authorKen VanDine <ken.vandine@canonical.com>2011-08-10 16:34:26 -0400
committerKen VanDine <ken.vandine@canonical.com>2011-08-10 16:34:26 -0400
commitae81953d3491fcadae3b05c9535c6605a50a9467 (patch)
treecb8a8cbf0ad10b45c3457852acd02790bcd7f2c2 /src/user-menu-mgr.c
parentf0c187f8dd55d8b831892ce30937aed2b737c5f8 (diff)
parentb5eb255fae2158fde84def56b46fa6c5424f5b84 (diff)
downloadayatana-indicator-session-ae81953d3491fcadae3b05c9535c6605a50a9467.tar.gz
ayatana-indicator-session-ae81953d3491fcadae3b05c9535c6605a50a9467.tar.bz2
ayatana-indicator-session-ae81953d3491fcadae3b05c9535c6605a50a9467.zip
* New upstream release.
- restart is missing from SessionMenu (LP: #815077) - Don't allow starting programs via the greeter indicators (LP: #811853) - Printer menu item should launch system-config-printer (LP: #818602) - gudev integration - apt restart required awareness * debian/control - Added build depends on libgudev-1.0-dev
Diffstat (limited to 'src/user-menu-mgr.c')
-rw-r--r--src/user-menu-mgr.c20
1 files changed, 16 insertions, 4 deletions
diff --git a/src/user-menu-mgr.c b/src/user-menu-mgr.c
index 611bcc7..bf3b77f 100644
--- a/src/user-menu-mgr.c
+++ b/src/user-menu-mgr.c
@@ -149,10 +149,9 @@ user_menu_mgr_rebuild_items (UserMenuMgr *self)
for (u = users; u != NULL; u = g_list_next (u)) {
user = u->data;
+ g_debug ("%p: %s", user, user->real_name);
user->service = self->users_dbus_interface;
- g_debug ("%i %s", (gint)user->uid, user->user_name);
-
if (g_strcmp0(user->user_name, "guest") == 0) {
/* Check to see if the guest has sessions and so therefore should
get a check mark. */
@@ -171,13 +170,26 @@ user_menu_mgr_rebuild_items (UserMenuMgr *self)
if (self->user_count > MINIMUM_USERS && self->user_count < MAXIMUM_USERS) {
mi = dbusmenu_menuitem_new ();
- dbusmenu_menuitem_property_set (mi, DBUSMENU_MENUITEM_PROP_TYPE, USER_ITEM_TYPE);
+ dbusmenu_menuitem_property_set (mi,
+ DBUSMENU_MENUITEM_PROP_TYPE,
+ USER_ITEM_TYPE);
if (user->real_name_conflict) {
gchar * conflictedname = g_strdup_printf("%s (%s)", user->real_name, user->user_name);
dbusmenu_menuitem_property_set (mi, USER_ITEM_PROP_NAME, conflictedname);
g_free(conflictedname);
} else {
- dbusmenu_menuitem_property_set (mi, USER_ITEM_PROP_NAME, user->real_name);
+ //g_debug ("%i %s", (gint)user->uid, user->real_name);
+ //g_debug ("users uid = %i", (gint)user->uid);
+ //g_debug ("users real name = %s", user->real_name);
+ if (user == NULL){
+ g_debug ("USER pointer is NULL");
+ return;
+ }
+ g_debug ("%p: %s", user, user->real_name);
+
+ dbusmenu_menuitem_property_set (mi,
+ USER_ITEM_PROP_NAME,
+ user->real_name);
}
dbusmenu_menuitem_property_set_bool (mi,
USER_ITEM_PROP_LOGGED_IN,