Finish and import the ThunarTreePane, ThunarTreeView and ThunarTreeModel classes (plus helper classes if any), which provide a traditional tree view instead of the shortcuts view.
Created attachment 412 thunar-tree-model.h Preliminary ThunarTreeModel header file (random hacking).
Created attachment 413 thunar-tree-model.c Preliminary ThunarTreeModel source file (random hacking).
To keep memory overhead as low as possible, there should be only one ThunarTreeModel instance (just like there's only a single ThunarShortcutsModel instance). This makes it tricky to decide which folder to load. The best way to address this issue is to make use of the ref_node() and unref_node() methods provided by the GtkTreeModel interface. Therefore we add a dummy element to every folder that is not yet expanded. Once ref_node() is called on this dummy node, we drop the dummy and load the real folder content instead (using a ThunarFolder). And vice versa, once unref_node() is called, we drop the node, and if this was the last node for a folder, we add the dummy node again. To keep things simple for the first release (1.0.0final milestone), we should provide only a single root item, which refers to the root directory. In later versions we could then add further root elements (e.g. "Home", "Removable Devices", etc.).
Committed with revision 20405. 2006-03-14 Benedikt Meurer <benny@xfce.org> * docs/README.thunarrc, thunar/thunar-preferences.c, thunar/thunar-preferences-dialog.c: Add new preferences TreeIconEmblems and TreeIconSize, similar to their shortcuts counterparts. * thunar/thunar-tree-model.{c,h}, thunar/thunar-tree-pane.{c,h}, thunar/thunar-tree-view.{c,h}, thunar/Makefile.am, thunar/thunar-window-ui.xml, thunar/thunar-window.c: Initial import of the tree side pane. Still missing a lot of features, but the basics are in place and the performance and memory overhead is quite good already. Bug #1363.