X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;f=src%2FPartSet%2FPartSet_DocumentDataModel.h;h=e059a1f4e50aef64493fdb5be4787fe70ac8b605;hb=65bd7c71b6eda2cad73adcc3be6c6ad725c26b94;hp=6ab69bf3c1ae52fa6d9da0c642dbcf257db5e1e9;hpb=18dab619179f5dd1f89aedce9154d6802b0de27f;p=modules%2Fshaper.git diff --git a/src/PartSet/PartSet_DocumentDataModel.h b/src/PartSet/PartSet_DocumentDataModel.h index 6ab69bf3c..e059a1f4e 100644 --- a/src/PartSet/PartSet_DocumentDataModel.h +++ b/src/PartSet/PartSet_DocumentDataModel.h @@ -146,7 +146,7 @@ Q_OBJECT enum { - PartsFolder = -100, + PartsFolder, HistoryNode, PartResult }; @@ -169,6 +169,9 @@ Q_OBJECT //! Removes sub-model on removing a part object. Also it removes QModelIndex-es which refer to this model void removeSubModel(int theModelId); + //! Removes sub-model on removing a part object. Also it removes QModelIndex-es which refer to this model + void removeSubModel(PartSet_PartModel* theModel); + //! Returns true if the given model is a one of sub-models (of both types) bool isSubModel(const QAbstractItemModel* theModel) const; @@ -183,22 +186,24 @@ Q_OBJECT int historyOffset() const; + PartSet_PartModel* findPartModel(FeaturePtr thePart) const; + + PartSet_PartModel* findPartModel(int thePosition) const; + //! Data model of top part of data tree (not parts object) PartSet_TopDataModel* myModel; //! Data models for Parts data tree representation (one data model per a one part) - QMap myPartModels; + QList myPartModels; //! Active part in part editing mode - int myActivePartId; + PartSet_PartModel* myActivePartModel; QModelIndex myActivePartIndex; //! List of saved QModelIndexes created by sub-models QList myIndexes; - int myHistoryBackOffset; - static QMap myIcons; };