X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;f=src%2FPartSet%2FPartSet_OperationPrs.h;h=ca3eaa2dd36d99cedac7848b63b7b2e8271957fe;hb=7b4a6a2a335d41a647e0f6a6becb7c23df042be1;hp=e296e7b1d9492e0f156ea79d67fb0a32390e3c8d;hpb=9ddba1caf0817c1e95c55d4c5b8ae6de23cbe6d5;p=modules%2Fshaper.git diff --git a/src/PartSet/PartSet_OperationPrs.h b/src/PartSet/PartSet_OperationPrs.h index e296e7b1d..ca3eaa2dd 100755 --- a/src/PartSet/PartSet_OperationPrs.h +++ b/src/PartSet/PartSet_OperationPrs.h @@ -11,6 +11,7 @@ #include #include +#include #include #include @@ -20,11 +21,18 @@ #include #include +#include + #include #include +#include + DEFINE_STANDARD_HANDLE(PartSet_OperationPrs, ViewerData_AISShape) +class XGUI_Workshop; +class XGUI_Displayer; + /** * \ingroup GUI * A redefinition of standard AIS Interactive Object in order to provide colored presentation of @@ -49,7 +57,7 @@ public: void setFeature(const FeaturePtr& theFeature); /// Returns true if the presentation - bool dependOn(const ObjectPtr& theObject); + //bool dependOn(const ObjectPtr& theObject); // Recompute internal list of shaped dependent on the current feature void updateShapes(); @@ -66,6 +74,13 @@ protected: Standard_EXPORT virtual void ComputeSelection(const Handle(SelectMgr_Selection)& aSelection, const Standard_Integer aMode) ; private: + /// Return true if the object is visible. If the object is feature, it returns true + /// if all results of the feature are shown + /// \param theDisplayer a displayer + /// \param theObject an object + /// \return a boolean value + bool isVisible(XGUI_Displayer* theDislayer, const ObjectPtr& theObject); + /// Fills the map by the feature object and shapes, which should be visuaziled /// Gets the feature attribute, collect objects to whom the attribute refers /// \param theObjectShape an output map of objects @@ -76,10 +91,18 @@ private: /// \return a boolean value static bool isSelectionAttribute(const AttributePtr& theAttribute); + /// Converts the current workshop to XGUI workshop + /// \return a workshop instance + XGUI_Workshop* workshop() const; + private: ModuleBase_IWorkshop* myWorkshop; FeaturePtr myFeature; /// Reference to a feature object - QMap > myFeatureShapes; + QMap > myFeatureShapes; /// visualized shapes + std::list myFeatureResults; /// visualized feature results + + Quantity_Color myShapeColor; /// color of feature depended shapes + Quantity_Color myResultColor; /// color of feature result };