gtk-demo: Improve a11y for applauncher
authorMatthias Clasen <mclasen@redhat.com>
Tue, 20 Jun 2023 01:06:50 +0000 (21:06 -0400)
committerMatthias Clasen <mclasen@redhat.com>
Tue, 20 Jun 2023 01:21:55 +0000 (21:21 -0400)
Use the new listitem properties to make
orca read the selected item in the applauncher
demo.

demos/gtk-demo/listview_applauncher.c

index e35b9587311c452e317017ba8b6ab6f64104d7d8..64f1a70f02c7880c496d6a9695dc15f0db8492c9 100644 (file)
@@ -79,6 +79,7 @@ bind_listitem_cb (GtkListItemFactory *factory,
 
   gtk_image_set_from_gicon (GTK_IMAGE (image), g_app_info_get_icon (app_info));
   gtk_label_set_label (GTK_LABEL (label), g_app_info_get_display_name (app_info));
+  gtk_list_item_set_accessible_label (list_item, g_app_info_get_display_name (app_info));
 }
 
 /* In more complex code, we would also need functions to unbind and teardown