summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorPablo Barciela <[email protected]>2018-04-02 21:39:26 +0200
committerPablo Barciela <[email protected]>2018-04-02 21:39:26 +0200
commitd20ceac2f5ae307b86e88600a19b71d3179a16e4 (patch)
tree268b6386c29107b68aa0d51b310e08d3d17f3c87 /src
parentffb953f469cd5ad42e3b8c0e02d677e0b8d41267 (diff)
downloadcaja-d20ceac2f5ae307b86e88600a19b71d3179a16e4.tar.bz2
caja-d20ceac2f5ae307b86e88600a19b71d3179a16e4.tar.xz
caja-side-pane.c: avoid deprecated GtkImageMenuItem
avoid deprecated: gtk_image_menu_item_new_with_label gtk_image_menu_item_set_image
Diffstat (limited to 'src')
-rw-r--r--src/caja-side-pane.c10
1 files changed, 6 insertions, 4 deletions
diff --git a/src/caja-side-pane.c b/src/caja-side-pane.c
index fc34e1ba..e22f517a 100644
--- a/src/caja-side-pane.c
+++ b/src/caja-side-pane.c
@@ -25,6 +25,7 @@
#include "caja-side-pane.h"
#include <eel/eel-glib-extensions.h>
+#include <eel/eel-gtk-extensions.h>
#include <eel/eel-gtk-macros.h>
#include <gdk/gdkkeysyms.h>
#include <gtk/gtk.h>
@@ -391,6 +392,9 @@ caja_side_pane_init (GObject *object)
TRUE, TRUE, 0);
side_pane->details->menu = gtk_menu_new ();
+
+ gtk_menu_set_reserve_toggle_size (GTK_MENU (side_pane->details->menu), FALSE);
+
g_signal_connect (side_pane->details->menu,
"deactivate",
G_CALLBACK (menu_deactivate_callback),
@@ -467,7 +471,8 @@ caja_side_pane_add_panel (CajaSidePane *side_pane,
gtk_widget_show (widget);
- panel->menu_item = gtk_image_menu_item_new_with_label (title);
+ panel->menu_item = eel_image_menu_item_new_from_icon (NULL, title);
+
gtk_widget_show (panel->menu_item);
gtk_menu_shell_append (GTK_MENU_SHELL (side_pane->details->menu),
panel->menu_item);
@@ -608,9 +613,6 @@ caja_side_pane_set_panel_image (CajaSidePane *side_pane,
image = NULL;
}
- gtk_image_menu_item_set_image (GTK_IMAGE_MENU_ITEM (panel->menu_item),
- image);
-
if (panel->shortcut)
{
gtk_widget_destroy (panel->shortcut);