PDA

View Full Version : populate tree upward



prasad_N
25th August 2015, 19:54
Hi,

I am working with tree view with huge data. so I wanted to do lazy population with the help of fetchMore() & canFetchMore() but this is intended to load data downwards (incremental data loading /population). I have a requirement on other side, I wanted to load and show last few rows(end of the tree) in tree view and then when I scroll up I wanted to load data in upward direction & show it.

Any suggestions from Qt experts how to implement this.

wysota
26th August 2015, 10:31
Basically you can manually do the same thing as treeview already does for canFetchMore/fetchMore. Connect to the changing value of the view's scrollbar and when it reaches the beginning, request new data to be prepended to the model.

prasad_N
26th August 2015, 12:32
That's what even I tough, But looking if some thing is there already.
Any how thanks for the reply, I will try this way.