[totem] Replace hack to set always-show-image for devices
- From: Robin Stocker <robinst src gnome org>
- To: svn-commits-list gnome org
- Cc:
- Subject: [totem] Replace hack to set always-show-image for devices
- Date: Sat, 5 Dec 2009 10:58:00 +0000 (UTC)
commit 2933258789b8e6de00ebc1c0db0b3b628395be54
Author: Robin Stocker <robin nibor org>
Date: Fri Dec 4 21:50:48 2009 +0100
Replace hack to set always-show-image for devices
https://bugzilla.gnome.org/show_bug.cgi?id=589808
src/totem-menu.c | 11 +----------
1 files changed, 1 insertions(+), 10 deletions(-)
---
diff --git a/src/totem-menu.c b/src/totem-menu.c
index 518ef29..fd7fc39 100644
--- a/src/totem-menu.c
+++ b/src/totem-menu.c
@@ -837,8 +837,6 @@ add_mount_to_menu (GMount *mount,
GIcon *icon;
const char *icon_name;
char *device_path;
- GtkWidget *menu_item;
- char *menu_item_path;
GVolume *volume;
GFile *root, *iso;
@@ -914,6 +912,7 @@ add_mount_to_menu (GMount *mount,
action = gtk_action_new (name, label, NULL, NULL);
g_object_set (G_OBJECT (action),
"icon-name", icon_name, NULL);
+ gtk_action_set_always_show_image (action, TRUE);
gtk_action_group_add_action (totem->devices_action_group, action);
g_object_unref (action);
@@ -921,14 +920,6 @@ add_mount_to_menu (GMount *mount,
"/tmw-menubar/movie/devices-placeholder", name, name,
GTK_UI_MANAGER_MENUITEM, FALSE);
- /* TODO: This can be made cleaner once bug #589842 is fixed */
- menu_item_path = g_strdup_printf ("/tmw-menubar/movie/devices-placeholder/%s", name);
- menu_item = gtk_ui_manager_get_widget (totem->ui_manager, menu_item_path);
- g_free (menu_item_path);
-
- if (menu_item != NULL)
- gtk_image_menu_item_set_always_show_image (GTK_IMAGE_MENU_ITEM (menu_item), TRUE);
-
g_free (name);
g_free (label);
g_object_unref (icon);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]