GNOME Bugzilla – Bug 111489
gtk.TreeSelcection doesn't wrap get_selected_rows
Last modified: 2004-12-22 21:47:04 UTC
The Function gtk_tree_selection_get_selected_rows returns a GLIST. I don't know enough about Python's C-API to make a patch for this (And the PC i'm working at doesn't have a decent C development environment (I'm using windows). I hope this isn't too much work to fix. (For others having the same problem: In the meantime I'm using: selected = [] selection_object.selected_foreach(lambda model, path, iter, sel = selected: sel.append(path)) But this isn't easy to read)
This is only availible in Gtk+ 2.2.x, and therefor cannot go in before pygtk 2.2.x (pygtk 2.0.x targets gtk 2.0.x)
Checked in an implementation to HEAD. Seems to work okay during my testing.
Thanks for fixing it. note: I can't try it at the moment (no longer working on the project using pygtk).