diff options
author | Sebastien Bacher <seb128@ubuntu.com> | 2012-08-23 16:05:11 +0200 |
---|---|---|
committer | Sebastien Bacher <seb128@ubuntu.com> | 2012-08-23 16:05:11 +0200 |
commit | da6785e18dc73a968ce57055754bcc2718d4e131 (patch) | |
tree | 81a2fd5f0dc1895f99e7eaec076f1e28afd0da67 /src/indicator-session.c | |
parent | e1ec25c1ccc63162bcfefc0661fc61fac9f376d1 (diff) | |
parent | 84e5c6a228d15a86f5a27300de45c6d2d28fc25b (diff) | |
download | ayatana-indicator-session-da6785e18dc73a968ce57055754bcc2718d4e131.tar.gz ayatana-indicator-session-da6785e18dc73a968ce57055754bcc2718d4e131.tar.bz2 ayatana-indicator-session-da6785e18dc73a968ce57055754bcc2718d4e131.zip |
Import upstream version 12.10.1
Diffstat (limited to 'src/indicator-session.c')
-rw-r--r-- | src/indicator-session.c | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/src/indicator-session.c b/src/indicator-session.c index 53ff87e..3038948 100644 --- a/src/indicator-session.c +++ b/src/indicator-session.c @@ -36,7 +36,6 @@ with this program. If not, see <http://www.gnu.org/licenses/>. #include <libindicator/indicator.h> #include <libindicator/indicator-object.h> #include <libindicator/indicator-service-manager.h> -#include <libindicator/indicator-image-helper.h> #include "shared-names.h" #include "user-widget.h" @@ -117,6 +116,8 @@ indicator_session_class_init (IndicatorSessionClass *klass) static void indicator_session_init (IndicatorSession *self) { + const gchar * icon_name; + self->settings = g_settings_new ("com.canonical.indicator.session"); /* Now let's fire these guys up. */ @@ -131,9 +132,8 @@ indicator_session_init (IndicatorSession *self) self->entry.name_hint = PACKAGE; self->entry.accessible_desc = _("Session Menu"); self->entry.label = GTK_LABEL (gtk_label_new ("User Name")); - self->entry.image = greeter_mode - ? indicator_image_helper (GREETER_ICON_DEFAULT) - : indicator_image_helper (ICON_DEFAULT); + icon_name = greeter_mode ? GREETER_ICON_DEFAULT : ICON_DEFAULT; + self->entry.image = GTK_IMAGE (gtk_image_new_from_icon_name (icon_name, GTK_ICON_SIZE_BUTTON)); self->entry.menu = GTK_MENU (dbusmenu_gtkmenu_new(INDICATOR_SESSION_DBUS_NAME, INDICATOR_SESSION_DBUS_OBJECT)); g_settings_bind (self->settings, "show-real-name-on-panel", @@ -341,7 +341,8 @@ receive_signal (GDBusProxy * proxy, } else if (!g_strcmp0(signal_name, "RestartRequired")) { - indicator_image_helper_update (self->entry.image, greeter_mode ? GREETER_ICON_RESTART : ICON_RESTART); + const gchar * icon_name = greeter_mode ? GREETER_ICON_RESTART : ICON_RESTART; + gtk_image_set_from_icon_name (GTK_IMAGE(self->entry.image), icon_name, GTK_ICON_SIZE_MENU); self->entry.accessible_desc = _("Device Menu (reboot required)"); g_signal_emit (G_OBJECT(self), INDICATOR_OBJECT_SIGNAL_ACCESSIBLE_DESC_UPDATE_ID, 0, &self->entry); } |