Re: [gtkmm] TreeModel question

Thanks Murray.
I will have a look at the new doc from time to time.

Yes, of course child rows are removed when their parent is removed.
Where would they be otherwise?

And, yes, an iterator is invalid after its row has been deleted. In
general, gtkmm iterators behave like Standard C++ iterators to standard
C++ containers.

The reference docs for TreeModel and friends have recently become
better, but are probably not online yet.

On Tue, 2004-02-10 at 08:14, Benoît Touron wrote:

Thanks Josh

I know this doc. Unfortunatly, it only explains how to iterate over rows, not remove rows. The reference doc it pretty poor as well. Nevertheless, I think that I just need to erase the connection node from the tree model (level 2), and it erases the underlying hosts too (level 3).
Thanks for your answer anyway.

When I needed to do this, I used the code from the docs.

That and the next section are pretty helpful. If it doesn't answer your question I can post my actual code, but I think their more generic example would be more helpful.

Benoît Touron wrote:

Hi !

First of all, thanks to Chris, Paulo and the other for their clues about my previons question (regarding threads).

Now, another issue:
I manage a treeView, containing 3 levels:
- the root level, managing a set of connections
- connections, managing hosts
- hosts

How can I remove a connection ? This means removing all the underlying hosts. I iterate into connection nodes, then for each connection, I iterate into its host nodes.
When I remove a host node, the iterator seems invalid.

How can I do this ?

gtkmm-list mailing list
gtkmm-list gnome org

gtkmm-list mailing list
gtkmm-list gnome org

gtkmm-list mailing list
gtkmm-list gnome org

[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]