X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;f=src%2FPartSet%2FPartSet_SketcherMgr.h;h=634916b7814fb3019823ab6dea15a4305e24547a;hb=77c928cf42b17926f8e493ce556b9cb09b4f97ae;hp=119764273f5168c1eb3a2b396c744aff27693eb6;hpb=613e672654df0f1e6838fb55b384842ce534809a;p=modules%2Fshaper.git diff --git a/src/PartSet/PartSet_SketcherMgr.h b/src/PartSet/PartSet_SketcherMgr.h index 119764273..634916b78 100644 --- a/src/PartSet/PartSet_SketcherMgr.h +++ b/src/PartSet/PartSet_SketcherMgr.h @@ -23,21 +23,23 @@ #include "PartSet.h" -#include "PartSet_Filters.h" -#include "PartSet_Tools.h" #include "PartSet_PreviewSketchPlane.h" +#include "XGUI_SelectionFilterType.h" +#include "PartSet_Tools.h" #include #include #include #include -#include #include #include #include + #include +#include + #include #include @@ -45,6 +47,8 @@ #include #include +#include + class PartSet_Module; class ModuleBase_IViewWindow; class ModuleBase_ModelWidget; @@ -194,15 +198,16 @@ public: /// \param theOperation a committed operation void commitNestedSketch(ModuleBase_Operation* theOperation); - /// Append the sketch selection filters in 3D viewer (plane and circle pointer) - void activateSelectionFilters(); - - // Remove sketch selection filter from the current viewer - virtual void deactivateSelectionFilters(); + /// Returns true if the filter is created by the sketch manager + /// \param theFilterType a checked type + /// \return boolean value + bool sketchSelectionFilter(const XGUI_SelectionFilterType theFilterType); - /// Append the sketch plane filter into the current viewer - /// \param toActivate state whether the filter should be activated/deactivated - void activatePlaneFilter(const bool& toActivate); + /// Append selection filter into the module and type of the filter in internal container + /// \param theFilterType selection filter type + /// \param theFilter added filter + void registerSelectionFilter(const XGUI_SelectionFilterType theFilterType, + const Handle(SelectMgr_Filter)& theFilter); /// Commit the operation if it is possible. If the operation is dimention constraint, /// it gives widget editor to input dimention value @@ -302,8 +307,9 @@ public: static const QStringList& constraintsIdList(); /// Returns a list of modes, where the AIS objects should be activated + /// \param theSketch a sketch object, modes are empty if sketch plane is not defined yet /// \param theModes a list of modes - static void sketchSelectionModes(QIntList& theModes); + static void sketchSelectionModes(const CompositeFeaturePtr& theSketch, QIntList& theModes); /// Create specific for the module presentation /// \param theResult an object for presentation @@ -439,8 +445,8 @@ private: CompositeFeaturePtr myCurrentSketch; - Handle(PartSet_CirclePointFilter) myCirclePointFilter; - Handle(ModuleBase_ShapeInPlaneFilter) myPlaneFilter; + std::set mySelectionFilterTypes; + FeatureToSelectionMap myCurrentSelection; bool myPreviousUpdateViewerEnabled;