From 8deab005c20eec262d6396049568fc47cccf28a9 Mon Sep 17 00:00:00 2001 From: sunflowerskater Date: Sat, 11 Feb 2023 14:59:19 -0300 Subject: general: Add missing tooltips to some buttons Acc. HIG, all controls from headerbars must have a tooltip. https://developer.gnome.org/hig/patterns/feedback/tooltips.html Fixes https://gitlab.gnome.org/GNOME/nautilus/-/issues/2754 --- src/nautilus-location-entry.c | 2 ++ src/nautilus-query-editor.c | 1 + src/nautilus-toolbar.c | 1 + 3 files changed, 4 insertions(+) diff --git a/src/nautilus-location-entry.c b/src/nautilus-location-entry.c index 4ae027c8f..1032caa34 100644 --- a/src/nautilus-location-entry.c +++ b/src/nautilus-location-entry.c @@ -707,6 +707,7 @@ nautilus_location_entry_set_secondary_action (NautilusLocationEntry *entry gtk_entry_set_icon_from_icon_name (GTK_ENTRY (entry), GTK_ENTRY_ICON_SECONDARY, "edit-clear-symbolic"); + gtk_entry_set_icon_tooltip_text (GTK_ENTRY (entry), GTK_ENTRY_ICON_SECONDARY, _("Clear Entry")); } break; @@ -715,6 +716,7 @@ nautilus_location_entry_set_secondary_action (NautilusLocationEntry *entry gtk_entry_set_icon_from_icon_name (GTK_ENTRY (entry), GTK_ENTRY_ICON_SECONDARY, "go-next-symbolic"); + gtk_entry_set_icon_tooltip_text (GTK_ENTRY (entry), GTK_ENTRY_ICON_SECONDARY, _("Go to Location")); } break; diff --git a/src/nautilus-query-editor.c b/src/nautilus-query-editor.c index 7de9dddd6..67afcc9ce 100644 --- a/src/nautilus-query-editor.c +++ b/src/nautilus-query-editor.c @@ -657,6 +657,7 @@ nautilus_query_editor_init (NautilusQueryEditor *editor) /* setup the filter menu button */ editor->dropdown_button = gtk_menu_button_new (); gtk_menu_button_set_icon_name (GTK_MENU_BUTTON (editor->dropdown_button), "funnel-symbolic"); + gtk_widget_set_tooltip_text (GTK_WIDGET (editor->dropdown_button), _("Filter Search Results")); gtk_menu_button_set_popover (GTK_MENU_BUTTON (editor->dropdown_button), editor->popover); gtk_widget_set_parent (editor->dropdown_button, GTK_WIDGET (editor)); gtk_widget_add_css_class (editor->dropdown_button, "circular"); diff --git a/src/nautilus-toolbar.c b/src/nautilus-toolbar.c index 397e9bdfe..90edc104c 100644 --- a/src/nautilus-toolbar.c +++ b/src/nautilus-toolbar.c @@ -235,6 +235,7 @@ nautilus_toolbar_constructed (GObject *object) gtk_box_append (GTK_BOX (self->location_entry_container), self->location_entry); self->location_entry_close_button = gtk_button_new_from_icon_name ("window-close-symbolic"); + gtk_widget_set_tooltip_text (self->location_entry_close_button, _("Cancel")); gtk_box_append (GTK_BOX (self->location_entry_container), self->location_entry_close_button); g_signal_connect (self->location_entry_close_button, "clicked", -- cgit v1.2.1