mirror of
https://gitlab.gnome.org/GNOME/gtk.git
synced 2025-01-01 08:20:36 +00:00
Merge branch 'static_text_widgets_are_not_special' into 'main'
a11y: Remove special handling of accessible names for static text widgets See merge request GNOME/gtk!6776
This commit is contained in:
commit
1fbc61f2cb
@ -1355,22 +1355,6 @@ gtk_at_context_get_text_accumulate (GtkATContext *self,
|
||||
}
|
||||
}
|
||||
|
||||
/* Step 2.G */
|
||||
if (GTK_IS_LABEL (self->accessible))
|
||||
{
|
||||
const char *text = gtk_label_get_text (GTK_LABEL (self->accessible));
|
||||
if (text && not_just_space (text))
|
||||
append_with_space (res, text);
|
||||
return;
|
||||
}
|
||||
else if (GTK_IS_INSCRIPTION (self->accessible))
|
||||
{
|
||||
const char *text = gtk_inscription_get_text (GTK_INSCRIPTION (self->accessible));
|
||||
if (text && not_just_space (text))
|
||||
append_with_space (res, text);
|
||||
return;
|
||||
}
|
||||
|
||||
/* Step 2.I */
|
||||
if (GTK_IS_WIDGET (self->accessible))
|
||||
{
|
||||
|
@ -805,6 +805,11 @@ gtk_inscription_set_text (GtkInscription *self,
|
||||
gtk_widget_queue_draw (GTK_WIDGET (self));
|
||||
|
||||
g_object_notify_by_pspec (G_OBJECT (self), properties[PROP_TEXT]);
|
||||
|
||||
gtk_accessible_update_property (GTK_ACCESSIBLE (self),
|
||||
GTK_ACCESSIBLE_PROPERTY_LABEL,
|
||||
text,
|
||||
-1);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -3086,6 +3086,11 @@ gtk_label_set_label_internal (GtkLabel *self,
|
||||
|
||||
g_object_notify_by_pspec (G_OBJECT (self), label_props[PROP_LABEL]);
|
||||
|
||||
gtk_accessible_update_property (GTK_ACCESSIBLE (self),
|
||||
GTK_ACCESSIBLE_PROPERTY_LABEL,
|
||||
self->label,
|
||||
-1);
|
||||
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user