One of my tasks in application development is to display the directory tree. In my case it is the tree of goods and services. I see several ways to solve this problem:
The contents of each folder are displayed in separate Activity, as
is done in the file manager. (this method is not for us)
Try to implement TreeView by inserting ExpandableListView into each other to obtain a higher level of nesting. Or use and improve ready-made solutions, such as this:
Develop with a clean slate.
Additional difficulty in development it's non-standard behavior of view that I have invented. The essence of the following:
When you click on a list item catalog this element rises to the top of the screen and pinned in the header (see the figure).
A list item that stood next, fixed at the bottom of the screen (footer).
All the empty space between these items takes the contents of the directory, which we chose. At the same time, this content can be to scroll. Attached top and bottom list items should remain in place.
Directory inside may also contain a directory. When we choosing child directory all the above steps are repeated for him.
In connection with the above, I would appreciate if you send in the right direction and advise which approach to choose to develop and effectively progressed in the right direction :). Thank you.
my tree: http://i.stack.imgur.com/uhpEn.jpg
You could use an Tree View for this.
Here's a short guide how we did it:
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.