mirror of
https://gitlab.gnome.org/GNOME/gtk.git
synced 2025-01-16 15:14:17 +00:00
inspector: Handle a11y being disabled
This commit is contained in:
parent
48d719e58e
commit
1a6d60b7d7
@ -238,6 +238,8 @@ update_name (GtkInspectorA11y *sl)
|
|||||||
char *name;
|
char *name;
|
||||||
|
|
||||||
context = gtk_accessible_get_at_context (GTK_ACCESSIBLE (sl->object));
|
context = gtk_accessible_get_at_context (GTK_ACCESSIBLE (sl->object));
|
||||||
|
if (context == NULL)
|
||||||
|
return;
|
||||||
|
|
||||||
name = gtk_at_context_get_name (context);
|
name = gtk_at_context_get_name (context);
|
||||||
gtk_label_set_label (GTK_LABEL (sl->name), name);
|
gtk_label_set_label (GTK_LABEL (sl->name), name);
|
||||||
@ -250,6 +252,8 @@ update_description (GtkInspectorA11y *sl)
|
|||||||
char *description;
|
char *description;
|
||||||
|
|
||||||
context = gtk_accessible_get_at_context (GTK_ACCESSIBLE (sl->object));
|
context = gtk_accessible_get_at_context (GTK_ACCESSIBLE (sl->object));
|
||||||
|
if (context == NULL)
|
||||||
|
return;
|
||||||
|
|
||||||
description = gtk_at_context_get_description (context);
|
description = gtk_at_context_get_description (context);
|
||||||
gtk_label_set_label (GTK_LABEL (sl->description), description);
|
gtk_label_set_label (GTK_LABEL (sl->description), description);
|
||||||
|
Loading…
Reference in New Issue
Block a user