GNOME Bugzilla – Bug 733782
GtkListBoxRowAccessible expects the parent to be a GtkListBox
Last modified: 2014-08-03 00:49:00 UTC
Created attachment 281765 [details] [review] Just add a GTK_IS_LIST_BOX check before using the parent ... which makes a cast to GtkListBoxRow fail. The attached patch fixes that by just also checking if the parent is a GtkListBox.
Review of attachment 281765 [details] [review]: Add list box rows to something other than a list box _should_ really fail. What are you adding your list box rows to ?
I'm adding it to a GtkBox. There was a similar case in the past where adding a GtkListBoxRow to something other than a GtListBox caused a crash and glade needed that to be fixed (because you need to edit rows and composite templates etc). I didn't see the assertion fail the last time I tried it in glade though, so that might be uninteresting. My case is most probably better solved using another widget.
ah, I guess glade is a valid case. So, it is probably a good idea to avoid crashing in this case.
Review of attachment 281765 [details] [review]: ok