mirror of
https://gitlab.gnome.org/GNOME/gtk.git
synced 2024-12-29 06:51:10 +00:00
a11y: Use the accessible type
This commit is contained in:
parent
0470b91add
commit
e5d5863a3f
@ -118,15 +118,16 @@ _gtk_renderer_cell_accessible_update_cache (GtkRendererCellAccessible *cell,
|
||||
}
|
||||
|
||||
AtkObject *
|
||||
_gtk_renderer_cell_accessible_new (void)
|
||||
_gtk_renderer_cell_accessible_new (GtkCellRenderer *renderer)
|
||||
{
|
||||
GObject *object;
|
||||
AtkObject *atk_object;
|
||||
AtkObject *object;
|
||||
|
||||
object = g_object_new (GTK_TYPE_RENDERER_CELL_ACCESSIBLE, NULL);
|
||||
g_return_val_if_fail (GTK_IS_CELL_RENDERER (renderer), NULL);
|
||||
|
||||
atk_object = ATK_OBJECT (object);
|
||||
atk_object->role = ATK_ROLE_TABLE_CELL;
|
||||
object = g_object_new (_gtk_cell_renderer_get_accessible_type (renderer),
|
||||
NULL);
|
||||
|
||||
return atk_object;
|
||||
atk_object_set_role (object, ATK_ROLE_TABLE_CELL);
|
||||
|
||||
return object;
|
||||
}
|
||||
|
@ -51,7 +51,8 @@ struct _GtkRendererCellAccessibleClass
|
||||
|
||||
GType _gtk_renderer_cell_accessible_get_type (void);
|
||||
|
||||
AtkObject *_gtk_renderer_cell_accessible_new (void);
|
||||
AtkObject *_gtk_renderer_cell_accessible_new (GtkCellRenderer * renderer);
|
||||
|
||||
gboolean _gtk_renderer_cell_accessible_update_cache (GtkRendererCellAccessible *cell,
|
||||
gboolean emit_change_signal);
|
||||
|
||||
|
@ -462,7 +462,7 @@ gtk_tree_view_accessible_ref_child (AtkObject *obj,
|
||||
else if (GTK_IS_CELL_RENDERER_PIXBUF (renderer))
|
||||
child = _gtk_image_cell_accessible_new ();
|
||||
else
|
||||
child = _gtk_renderer_cell_accessible_new ();
|
||||
child = _gtk_renderer_cell_accessible_new (renderer);
|
||||
|
||||
cell = GTK_CELL_ACCESSIBLE (child);
|
||||
renderer_cell = GTK_RENDERER_CELL_ACCESSIBLE (child);
|
||||
|
Loading…
Reference in New Issue
Block a user