Re: Moving GtkTreeStore Items
- From: Havoc Pennington <hp redhat com>
- To: Brett Nash <nash nash nu>
- Cc: gtk-app-devel-list gnome org
- Subject: Re: Moving GtkTreeStore Items
- Date: 09 Jun 2002 18:17:43 -0400
Brett Nash <nash nash nu> writes:
Is there is an easy way to move an item in a gtk tree store
to another point.
Basically I have:
And I want to move 'Blah' from beneath Foo, to beneath Frob.
I can do it by manually making a new row, then copying all the data,
then removing the old row, but I would prefer not to.
That's what you have to do. If there were a gtk_tree_model_move() then
it would just do that for you (though it might be possible to avoid
the copy). You can also write a custom GtkTreeModel of course.
As a second question:
Is there a equivelent of gtk_clist_freeze/thaw for Tree views?
No but you shouldn't need it. (Removing the model from the view,
changing the model, putting the model back would be fairly equivalent,
but is probably a bad idea.)
] [Thread Prev