mirror of
https://gitlab.gnome.org/GNOME/gtk.git
synced 2024-12-28 22:41:43 +00:00
passwordentry: Change an accessible role
The caps-lock icon is really an alert. Maybe this is in vain, since orca ignores these images.
This commit is contained in:
parent
2349f13f45
commit
aada893352
@ -208,7 +208,10 @@ gtk_password_entry_init (GtkPasswordEntry *entry)
|
||||
g_signal_connect_swapped (entry->entry, "notify::has-focus", G_CALLBACK (focus_changed), entry);
|
||||
g_signal_connect_swapped (entry->entry, "activate", G_CALLBACK (activate_cb), entry);
|
||||
|
||||
entry->icon = gtk_image_new_from_icon_name ("caps-lock-symbolic");
|
||||
entry->icon = g_object_new (GTK_TYPE_IMAGE,
|
||||
"icon-name", "caps-lock-symbolic",
|
||||
"accessible-role", GTK_ACCESSIBLE_ROLE_ALERT,
|
||||
NULL);
|
||||
gtk_widget_set_tooltip_text (entry->icon, _("Caps Lock is on"));
|
||||
gtk_widget_add_css_class (entry->icon, "caps-lock-indicator");
|
||||
gtk_widget_set_cursor (entry->icon, gtk_widget_get_cursor (entry->entry));
|
||||
|
Loading…
Reference in New Issue
Block a user