[prev in list] [next in list] [prev in thread] [next in thread] 

List:       gtk
Subject:    Re: Has anyone been able to force TreeView expander with no children?
From:       Holger Berndt <berndth () gmx ! de>
Date:       2009-10-15 16:36:27
Message-ID: 20091015163641.E4FB4750069 () menubar ! gnome ! org
[Download RAW message or body]

Hi Daniel,

On Mi, 14.10.2009 18:52, Daniel B. Thurman wrote:

>I need
>the expanders so that when I expand the directory
>in question, I would then trigger a call to add more
>children, and so on.

The way I do that is to add a single dummy child (with a text like
"Loading..."). That makes the top level entry expandable. When
the user expands the item, he gets feedback right away by seeing the
"Loading..." entry, while the code populates the model on the fly, and
finally removes the dummy entry.

Others (e.g. Nautilus list view) seem to do it similarly.

Holger
_______________________________________________
gtk-list mailing list
gtk-list@gnome.org
http://mail.gnome.org/mailman/listinfo/gtk-list
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic