aboutsummaryrefslogtreecommitdiffstats
path: root/widgets
diff options
context:
space:
mode:
authorMilan Crha <mcrha@redhat.com>2011-06-06 21:54:19 +0800
committerMilan Crha <mcrha@redhat.com>2011-06-06 21:54:19 +0800
commit8f01d97298b6f7d226fc5df4a0d8afe8f78c55c1 (patch)
tree221c20725189fb0b9bca213470967c9ee744fc2c /widgets
parent76a81251dd3f7603fbc7c667a00606bf4be1428a (diff)
downloadgsoc2013-evolution-8f01d97298b6f7d226fc5df4a0d8afe8f78c55c1.tar.gz
gsoc2013-evolution-8f01d97298b6f7d226fc5df4a0d8afe8f78c55c1.tar.zst
gsoc2013-evolution-8f01d97298b6f7d226fc5df4a0d8afe8f78c55c1.zip
Bug #643526 - Crash in et_get_n_children
Diffstat (limited to 'widgets')
-rw-r--r--widgets/table/gal-a11y-e-table.c7
-rw-r--r--widgets/table/gal-a11y-e-tree.c3
2 files changed, 5 insertions, 5 deletions
diff --git a/widgets/table/gal-a11y-e-table.c b/widgets/table/gal-a11y-e-table.c
index 5db3f44b22..436de1ec0f 100644
--- a/widgets/table/gal-a11y-e-table.c
+++ b/widgets/table/gal-a11y-e-table.c
@@ -131,7 +131,7 @@ et_get_n_children (AtkObject *accessible)
et = E_TABLE (gtk_accessible_get_widget (GTK_ACCESSIBLE (a11y)));
- if (et->group) {
+ if (et && et->group) {
if (E_IS_TABLE_GROUP_LEAF (et->group))
n = 1;
else if (E_IS_TABLE_GROUP_CONTAINER (et->group)) {
@@ -155,6 +155,8 @@ et_ref_child (AtkObject *accessible,
gint child_no;
et = E_TABLE (gtk_accessible_get_widget (GTK_ACCESSIBLE (a11y)));
+ if (!et)
+ return NULL;
child_no = et_get_n_children (accessible);
if (i == 0 || i < child_no - 1) {
@@ -283,8 +285,7 @@ gal_a11y_e_table_new (GObject *widget)
a11y = g_object_new (gal_a11y_e_table_get_type (), NULL);
- /* FIXME No way to do this in GTK 3. */
- /*GTK_ACCESSIBLE (a11y)->widget = GTK_WIDGET (widget);*/
+ gtk_accessible_set_widget (GTK_ACCESSIBLE (a11y), GTK_WIDGET (widget));
/* we need to init all the children for multiple table items */
if (table && gtk_widget_get_mapped (GTK_WIDGET (table)) && table->group && E_IS_TABLE_GROUP_CONTAINER (table->group)) {
diff --git a/widgets/table/gal-a11y-e-tree.c b/widgets/table/gal-a11y-e-tree.c
index 4507e21363..f26c525550 100644
--- a/widgets/table/gal-a11y-e-tree.c
+++ b/widgets/table/gal-a11y-e-tree.c
@@ -178,8 +178,7 @@ gal_a11y_e_tree_new (GObject *widget)
a11y = g_object_new (gal_a11y_e_tree_get_type (), NULL);
- /* FIXME No way to do this in GTK 3. */
- /*GTK_ACCESSIBLE (a11y)->widget = GTK_WIDGET (widget);*/
+ gtk_accessible_set_widget (GTK_ACCESSIBLE (a11y), GTK_WIDGET (widget));
return ATK_OBJECT (a11y);
}