Tree View #97
Replies: 1 comment 1 reply
-
|
Cool idea, I think people will enjoy this. Adding "Hierarchical Tree" to the Path Display Style options makes sense from a user's point of view. I agree with your general implementation idea. I'd turn FileList into a QTreeView and then rework FileListModel so that the QModelIndexes can have parents/children (see SidebarModel). It would be great if the collapsed/expanded state stays somewhat stable after staging/unstaging, and across Jump tasks. Feel free to share a WIP branch and I'll see if I can help with your edge cases when I have time. Daydreaming about stretch goals below: 1: Once the new model is working, FileList actions should become "tree-aware" so that, for example, staging a folder affects all leaf nodes in the folder. But I have a hunch that this is going to add a lot of work + tests, so we can totally decide that folder-specific actions are out of scope for the first implementation for now. (In this case, can we make folders non-selectable?) 2: Squash chains of directories so that the parent node of |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
I'd be interested in adding an option for a hierarchical tree view instead of a list view in the file list. I wanted to ask a bit about how it should best be implemented.
I did make a prototype switching out QListView for QTreeView in the filelist and got it kind of working but there are a few edge cases I didn't address, like when switching back to a flattened listlike view the contents would not refresh until interacted with. I also wasn't sure how to best expose the option. Would it make sense to have it as a "Path Display" or as a separate option that overrides path display entirely?
Curious to hear what people have to think!
Beta Was this translation helpful? Give feedback.
All reactions