--- ./gtk/gtkcolorswatch.c.orig 2024-07-10 12:03:14.000000000 -0500 +++ ./gtk/gtkcolorswatch.c 2025-09-17 23:11:01.159154126 -0500 @@ -350,4 +350,15 @@ if (swatch->priv->popover == NULL) { + GtkWidget *item; + swatch->priv->popover = gtk_menu_new (); + item = gtk_menu_item_new_with_mnemonic (_ ("C_ustomize")); + g_signal_connect_swapped (item, "activate", G_CALLBACK (emit_customize), swatch); + gtk_widget_set_visible (GTK_WIDGET (item), TRUE); + gtk_menu_shell_append (GTK_MENU_SHELL (swatch->priv->popover), item); + } + gtk_menu_popup_at_pointer (GTK_MENU (swatch->priv->popover), NULL); + return; + if (swatch->priv->popover == NULL) + { GtkWidget *box; GtkWidget *item; --- ./gtk/gtkfilechooserwidget.c.orig 2025-09-17 23:10:25.250154977 -0500 +++ ./gtk/gtkfilechooserwidget.c 2025-09-17 23:11:01.162154126 -0500 @@ -30,4 +30,5 @@ #include "gtkcellrenderertext.h" #include "gtkcheckmenuitem.h" +#include "deprecated/gtkimagemenuitem.h" #include "gtkclipboard.h" #include "gtkcomboboxtext.h" @@ -2286,4 +2287,8 @@ GtkWidget *separator; + separator = gtk_separator_menu_item_new (); + gtk_widget_set_visible (GTK_WIDGET (separator), TRUE); + gtk_menu_shell_append (GTK_MENU_SHELL (box), separator); + return separator; separator = g_object_new (GTK_TYPE_SEPARATOR, "orientation", GTK_ORIENTATION_HORIZONTAL, @@ -2307,4 +2312,12 @@ GtkWidget *item; + if (g_str_match_string ("toggle", action, TRUE)) + item = gtk_check_menu_item_new_with_mnemonic (label); + else + item = gtk_image_menu_item_new_with_mnemonic (label); + g_object_set (G_OBJECT (item), "action-name", action, NULL); + gtk_widget_set_visible (GTK_WIDGET (item), TRUE); + gtk_menu_shell_append (GTK_MENU_SHELL (box), item); + return item; item = g_object_new (GTK_TYPE_MODEL_BUTTON, "visible", TRUE, @@ -2331,4 +2344,7 @@ gtk_widget_show (box); gtk_container_add (GTK_CONTAINER (priv->browse_files_popover), box); + priv->browse_files_popover = gtk_menu_new (); + gtk_menu_attach_to_widget (GTK_MENU (priv->browse_files_popover), GTK_WIDGET (priv->browse_files_tree_view), NULL); + box = priv->browse_files_popover; priv->visit_file_item = add_button (box, _("_Visit File"), "item.visit"); @@ -2347,4 +2363,10 @@ priv->show_time_item = add_button (box, _("Show _Time"), "item.toggle-show-time"); priv->sort_directories_item = add_button (box, _("Sort _Folders before Files"), "item.toggle-sort-dirs-first"); + g_object_set (priv->visit_file_item, "image", gtk_image_new_from_icon_name ("go-jump", GTK_ICON_SIZE_MENU), NULL); + g_object_set (priv->open_folder_item, "image", gtk_image_new_from_icon_name ("folder-open", GTK_ICON_SIZE_MENU), NULL); + g_object_set (priv->copy_file_location_item, "image", gtk_image_new_from_icon_name ("edit-copy", GTK_ICON_SIZE_MENU), NULL); + g_object_set (priv->add_shortcut_item, "image", gtk_image_new_from_icon_name ("gtk-add", GTK_ICON_SIZE_MENU), NULL); + g_object_set (priv->delete_file_item, "image", gtk_image_new_from_icon_name ("edit-delete", GTK_ICON_SIZE_MENU), NULL); + g_object_set (priv->trash_file_item, "image", gtk_image_new_from_icon_name ("user-trash",GTK_ICON_SIZE_MENU), NULL); } @@ -2406,4 +2428,6 @@ file_list_update_popover (impl); + gtk_menu_popup_at_pointer (GTK_MENU (priv->browse_files_popover), NULL); + return; selection = gtk_tree_view_get_selection (GTK_TREE_VIEW (priv->browse_files_tree_view)); --- ./gtk/gtkplacessidebar.c.orig 2025-09-17 23:10:25.248154977 -0500 +++ ./gtk/gtkplacessidebar.c 2025-09-17 23:11:01.164154126 -0500 @@ -65,4 +65,5 @@ #include "gtkbox.h" #include "gtkmodelbutton.h" +#include "deprecated/gtkimagemenuitem.h" /** @@ -2347,6 +2348,6 @@ /* Adjust start/stop items to reflect the type of the drive */ - g_object_set (data->start_item, "text", _("_Start"), NULL); - g_object_set (data->stop_item, "text", _("_Stop"), NULL); + g_object_set (data->start_item, "label", _("_Start"), "use_underline", TRUE, NULL); + g_object_set (data->stop_item, "label", _("_Stop"), "use_underline", TRUE, NULL); if ((show_start || show_stop) && drive != NULL) { @@ -2355,22 +2356,22 @@ case G_DRIVE_START_STOP_TYPE_SHUTDOWN: /* start() for type G_DRIVE_START_STOP_TYPE_SHUTDOWN is normally not used */ - g_object_set (data->start_item, "text", _("_Power On"), NULL); - g_object_set (data->stop_item, "text", _("_Safely Remove Drive"), NULL); + g_object_set (data->start_item, "label", _("_Power On"), "use_underline", TRUE, NULL); + g_object_set (data->stop_item, "label", _("_Safely Remove Drive"), "use_underline", TRUE, NULL); break; case G_DRIVE_START_STOP_TYPE_NETWORK: - g_object_set (data->start_item, "text", _("_Connect Drive"), NULL); - g_object_set (data->stop_item, "text", _("_Disconnect Drive"), NULL); + g_object_set (data->start_item, "label", _("_Connect Drive"), "use_underline", TRUE, NULL); + g_object_set (data->stop_item, "label", _("_Disconnect Drive"), "use_underline", TRUE, NULL); break; case G_DRIVE_START_STOP_TYPE_MULTIDISK: - g_object_set (data->start_item, "text", _("_Start Multi-disk Device"), NULL); - g_object_set (data->stop_item, "text", _("_Stop Multi-disk Device"), NULL); + g_object_set (data->start_item, "label", _("_Start Multi-disk Device"), "use_underline", TRUE, NULL); + g_object_set (data->stop_item, "label", _("_Stop Multi-disk Device"), "use_underline", TRUE, NULL); break; case G_DRIVE_START_STOP_TYPE_PASSWORD: /* stop() for type G_DRIVE_START_STOP_TYPE_PASSWORD is normally not used */ - g_object_set (data->start_item, "text", _("_Unlock Device"), NULL); - g_object_set (data->stop_item, "text", _("_Lock Device"), NULL); + g_object_set (data->start_item, "label", _("_Unlock Device"), "use_underline", TRUE, NULL); + g_object_set (data->stop_item, "label", _("_Lock Device"), "use_underline", TRUE, NULL); break; @@ -3565,4 +3566,11 @@ GtkWidget *separator; + if (GTK_IS_MENU (box)) + { + separator = gtk_separator_menu_item_new(); + gtk_widget_set_visible(GTK_WIDGET(separator), TRUE); + gtk_menu_shell_append(GTK_MENU_SHELL(box), separator); + return separator; + } separator = g_object_new (GTK_TYPE_SEPARATOR, "orientation", GTK_ORIENTATION_HORIZONTAL, @@ -3583,4 +3591,12 @@ GtkWidget *item; + if (GTK_IS_MENU (box)) + { + item = gtk_image_menu_item_new_with_mnemonic(label); + g_object_set(G_OBJECT(item), "action-name", action, NULL); + gtk_widget_set_visible(GTK_WIDGET(item), TRUE); + gtk_menu_shell_append(GTK_MENU_SHELL(box), item); + return item; + } item = g_object_new (GTK_TYPE_MODEL_BUTTON, "visible", TRUE, @@ -3600,4 +3616,15 @@ GtkWidget *item; + if (GTK_IS_MENU (box)) + { + item = gtk_image_menu_item_new_with_mnemonic (label); + g_object_set(G_OBJECT (item), + "action-name", flags == GTK_PLACES_OPEN_NORMAL ? "row.open" : "row.open-other", + "action-target", g_variant_new_int32 (flags), + NULL); + gtk_widget_set_visible (GTK_WIDGET (item), TRUE); + gtk_menu_shell_append (GTK_MENU_SHELL (box), item); + return item; + } item = g_object_new (GTK_TYPE_MODEL_BUTTON, "visible", TRUE, @@ -3705,4 +3732,11 @@ gtk_widget_show (box); gtk_container_add (GTK_CONTAINER (sidebar->popover), box); + if (!sidebar->populate_all) + { + sidebar->popover = gtk_menu_new (); + g_signal_connect (sidebar->popover, "destroy", G_CALLBACK (on_row_popover_destroy), sidebar); + gtk_menu_attach_to_widget (GTK_MENU (sidebar->popover), GTK_WIDGET (sidebar), NULL); + box = sidebar->popover; + } add_open_button (box, _("_Open"), GTK_PLACES_OPEN_NORMAL); @@ -3728,4 +3762,13 @@ data.start_item = add_button (box, _("_Start"), "row.start"); data.stop_item = add_button (box, _("_Stop"), "row.stop"); + if (!sidebar->populate_all) + { + g_object_set ( + g_list_first (gtk_container_get_children (GTK_CONTAINER (box)))->data, + "image", gtk_image_new_from_icon_name ("folder-open", GTK_ICON_SIZE_MENU), NULL + ); + g_object_set (data.remove_item, "image", gtk_image_new_from_icon_name("list-remove",GTK_ICON_SIZE_MENU), NULL); + g_object_set (data.add_shortcut_item, "image", gtk_image_new_from_icon_name("list-add", GTK_ICON_SIZE_MENU), NULL); + } /* Update everything! */ @@ -3771,4 +3814,11 @@ create_row_popover (sidebar, row); + if (GTK_IS_MENU (sidebar->popover)) + { + sidebar->context_row = row; + gtk_menu_popup_at_pointer (GTK_MENU (sidebar->popover), NULL); + g_object_unref (sidebar); + return; + } gtk_popover_set_relative_to (GTK_POPOVER (sidebar->popover), GTK_WIDGET (row));