Qt Model/tree view as a wrapper tree display for under-lying tree data-structure
-
wrote on 19 Nov 2012, 07:29 last edited by
Hello,
I've my own tree data-structure which i want to display using Qt model/tree view framework. The underlying tree structure will changing frequently (like insertion and deletion of children) through its own other interfaces. Do I have to take some extra measures to make sure that the underlying data structure is displayed properly without any breaks? -
wrote on 19 Nov 2012, 07:47 last edited by
do u think in implementing ur own Model?
-
wrote on 19 Nov 2012, 08:43 last edited by
I've my own tree data structure which is not a model. Now i've another class cMyModel subclassing QAbstractItemModel. This cMyModel acts as a wrapper of my tree data structure. My tree data structure has its own interfaces/methods through which the tree structure will be changing frequently. Hope you understand my case. My question remains the same
-
wrote on 19 Nov 2012, 14:22 last edited by
Yes, you do have to take some measures. One important one is that you need to signal changes in the data store before they happen, as well as when they are done. Otherwise, you'll have problems implementing the model properly.
4/4