[metacity] menu.c: fix deprecated warnings Stop using image menu items. It is deprecated since gtk 3.10 version
- From: Alberts Muktupāvels <muktupavels src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [metacity] menu.c: fix deprecated warnings Stop using image menu items. It is deprecated since gtk 3.10 version
- Date: Wed, 4 Jun 2014 16:24:45 +0000 (UTC)
commit 5aecb8336c6c90a9ad1bb46295ca60624f5a44aa
Author: Alberts Muktupāvels <alberts muktupavels gmail com>
Date: Wed Jun 4 19:03:57 2014 +0300
menu.c: fix deprecated warnings
Stop using image menu items. It is deprecated since gtk 3.10
version.
src/ui/menu.c | 17 +++--------------
1 files changed, 3 insertions(+), 14 deletions(-)
---
diff --git a/src/ui/menu.c b/src/ui/menu.c
index 4bad592..8a35583 100644
--- a/src/ui/menu.c
+++ b/src/ui/menu.c
@@ -38,7 +38,6 @@ typedef enum
{
MENU_ITEM_SEPARATOR = 0,
MENU_ITEM_NORMAL,
- MENU_ITEM_IMAGE,
MENU_ITEM_CHECKBOX,
MENU_ITEM_RADIOBUTTON,
MENU_ITEM_WORKSPACE_LIST,
@@ -64,9 +63,9 @@ static void activate_cb (GtkWidget *menuitem, gpointer data);
static MenuItem menuitems[] = {
/* Translators: Translate this string the same way as you do in libwnck! */
- { META_MENU_OP_MINIMIZE, MENU_ITEM_IMAGE, METACITY_STOCK_MINIMIZE, FALSE, N_("Mi_nimize") },
+ { META_MENU_OP_MINIMIZE, MENU_ITEM_NORMAL, NULL, FALSE, N_("Mi_nimize") },
/* Translators: Translate this string the same way as you do in libwnck! */
- { META_MENU_OP_MAXIMIZE, MENU_ITEM_IMAGE, METACITY_STOCK_MAXIMIZE, FALSE, N_("Ma_ximize") },
+ { META_MENU_OP_MAXIMIZE, MENU_ITEM_NORMAL, NULL, FALSE, N_("Ma_ximize") },
/* Translators: Translate this string the same way as you do in libwnck! */
{ META_MENU_OP_UNMAXIMIZE, MENU_ITEM_NORMAL, NULL, FALSE, N_("Unma_ximize") },
/* Translators: Translate this string the same way as you do in libwnck! */
@@ -99,7 +98,7 @@ static MenuItem menuitems[] = {
{ 0, MENU_ITEM_WORKSPACE_LIST, NULL, FALSE, NULL },
{ 0, MENU_ITEM_SEPARATOR, NULL, FALSE, NULL }, /* separator */
/* Translators: Translate this string the same way as you do in libwnck! */
- { META_MENU_OP_DELETE, MENU_ITEM_IMAGE, METACITY_STOCK_DELETE, FALSE, N_("_Close") }
+ { META_MENU_OP_DELETE, MENU_ITEM_NORMAL, NULL, FALSE, N_("_Close") }
};
static void
@@ -272,16 +271,6 @@ menu_item_new (MenuItem *menuitem, int workspace_id)
{
mi = gtk_menu_item_new ();
}
- else if (menuitem->type == MENU_ITEM_IMAGE)
- {
- GtkWidget *image;
-
- image = gtk_image_new_from_stock (menuitem->stock_id, GTK_ICON_SIZE_MENU);
- mi = gtk_image_menu_item_new ();
-
- gtk_image_menu_item_set_image (GTK_IMAGE_MENU_ITEM (mi), image);
- gtk_widget_show (image);
- }
else if (menuitem->type == MENU_ITEM_CHECKBOX)
{
mi = gtk_check_menu_item_new ();
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]