summaryrefslogtreecommitdiff
path: root/examples
diff options
context:
space:
mode:
authorMatthias Clasen <mclasen@redhat.com>2021-03-08 00:43:03 -0500
committerMatthias Clasen <mclasen@redhat.com>2021-06-05 08:49:17 -0400
commit46d1f04a7c61eeeba158405a4c59547be419d274 (patch)
treec1eb173e983937e70073b5ef2c98c22288319e15 /examples
parent1605ec0a44c8cb131d8c9ff66008609058d7089c (diff)
downloadgtk+-46d1f04a7c61eeeba158405a4c59547be419d274.tar.gz
bloatpad: Bring back the menubar
This was lost at some point.
Diffstat (limited to 'examples')
-rw-r--r--examples/bp/bloatpad.c11
1 files changed, 6 insertions, 5 deletions
diff --git a/examples/bp/bloatpad.c b/examples/bp/bloatpad.c
index b29b639241..d429318fc8 100644
--- a/examples/bp/bloatpad.c
+++ b/examples/bp/bloatpad.c
@@ -220,6 +220,7 @@ new_window (GApplication *app,
gtk_window_set_default_size ((GtkWindow*)window, 640, 480);
g_action_map_add_action_entries (G_ACTION_MAP (window), win_entries, G_N_ELEMENTS (win_entries), window);
gtk_window_set_title (GTK_WINDOW (window), "Bloatpad");
+ gtk_application_window_set_show_menubar (GTK_APPLICATION_WINDOW (window), TRUE);
grid = gtk_grid_new ();
gtk_window_set_child (GTK_WINDOW (window), grid);
@@ -536,7 +537,7 @@ bloat_pad_startup (GApplication *application)
menu = gtk_application_get_menu_by_id (GTK_APPLICATION (application), "icon-menu");
- file = g_file_new_for_uri ("resource:///org/gtk/libgtk/icons/16x16/actions/gtk-select-color.png");
+ file = g_file_new_for_uri ("resource:///org/gtk/libgtk/icons/16x16/actions/insert-image.png");
icon = g_file_icon_new (file);
item = g_menu_item_new ("File Icon", NULL);
g_menu_item_set_icon (item, icon);
@@ -552,7 +553,7 @@ bloat_pad_startup (GApplication *application)
g_object_unref (item);
g_object_unref (icon);
- bytes = g_resources_lookup_data ("/org/gtk/libgtk/icons/16x16/actions/gtk-select-font.png", 0, NULL);
+ bytes = g_resources_lookup_data ("/org/gtk/libgtk/icons/16x16/actions/media-eject.png", 0, NULL);
icon = g_bytes_icon_new (bytes);
item = g_menu_item_new ("Bytes Icon", NULL);
g_menu_item_set_icon (item, icon);
@@ -561,19 +562,19 @@ bloat_pad_startup (GApplication *application)
g_object_unref (icon);
g_bytes_unref (bytes);
- icon = G_ICON (gdk_pixbuf_new_from_resource ("/org/gtk/libgtk/icons/16x16/actions/gtk-preferences.png", NULL));
+ icon = G_ICON (gdk_pixbuf_new_from_resource ("/org/gtk/libgtk/icons/16x16/actions/folder-new.png", NULL));
item = g_menu_item_new ("Pixbuf", NULL);
g_menu_item_set_icon (item, icon);
g_menu_append_item (menu, item);
g_object_unref (item);
g_object_unref (icon);
- file = g_file_new_for_uri ("resource:///org/gtk/libgtk/icons/16x16/actions/gtk-page-setup.png");
+ file = g_file_new_for_uri ("resource:///org/gtk/libgtk/icons/16x16/actions/bookmark-new.png");
icon = g_file_icon_new (file);
emblem = g_emblem_new (icon);
g_object_unref (icon);
g_object_unref (file);
- file = g_file_new_for_uri ("resource:///org/gtk/libgtk/icons/16x16/actions/gtk-orientation-reverse-portrait.png");
+ file = g_file_new_for_uri ("resource:///org/gtk/libgtk/icons/16x16/actions/dialog-warning.png");
icon2 = g_file_icon_new (file);
icon = g_emblemed_icon_new (icon2, emblem);
item = g_menu_item_new ("Emblemed Icon", NULL);