X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;f=src%2FModuleBase%2FModuleBase_IModule.h;h=d80620a4895a15befa1605d1c770b1b7b465600d;hb=29dfb8a802f61cacf5f57fb79c62badee00ebcdf;hp=45c895ded35147f81ab5f3727f49997f4773b8cc;hpb=e1fe93d90eb9de8f45ad0ba420a2811f40fcaf91;p=modules%2Fshaper.git diff --git a/src/ModuleBase/ModuleBase_IModule.h b/src/ModuleBase/ModuleBase_IModule.h index 45c895ded..d80620a48 100755 --- a/src/ModuleBase/ModuleBase_IModule.h +++ b/src/ModuleBase/ModuleBase_IModule.h @@ -34,9 +34,9 @@ class MODULEBASE_EXPORT ModuleBase_IModule : public QObject public: /// enumeration to know which objects should be customized enum ModuleBase_CustomizeFlag { - CustomizeDependedAndResults = 0x00000000, - CustomizeHighlightedObjects = 0x00000001, - CustomizeAllObjects = CustomizeDependedAndResults | CustomizeHighlightedObjects + CustomizeArguments = 0, /// references of other objects referenced to the current feature + CustomizeResults, /// results of the current feature + CustomizeHighlightedObjects /// highlighted objects of the active widget }; /// Constructor @@ -160,15 +160,28 @@ class MODULEBASE_EXPORT ModuleBase_IModule : public QObject /// \param theModes a list of modes virtual void activeSelectionModes(QIntList& theModes) {} - /** Update the object presentable properties such as color, lines width and other - * If the object is result with the color attribute value set, it is used, - * otherwise the customize is applyed to the object's feature if it is a custom prs - * \param theObject an object instance - * \param theFlag a flag of level of customization, which means that only part of sub-elements - * should be updated(e.g. only highlighted elements) - * \param theUpdateViewer the parameter whether the viewer should be update immediately - * \returns true if the object is modified - */ + /// Activate custom presentation for the object. Default realization is empty. + /// \param theObject an object instance + /// \param theFlag a flag of level of customization, which means that only part of sub-elements + /// \param theUpdateViewer the parameter whether the viewer should be update immediately + virtual void activateCustomPrs(const FeaturePtr& theFeature, + const ModuleBase_CustomizeFlag& theFlag, + const bool theUpdateViewer) {} + + /// Deactivate custom presentation for the object. Default realization is empty. + /// \param theFlag a flag of level of customization, which means that only part of sub-elements + /// \param theUpdateViewer the parameter whether the viewer should be update immediately + virtual void deactivateCustomPrs(const ModuleBase_CustomizeFlag& theFlag, + const bool theUpdateViewer) {} + + /// Update the object presentable properties such as color, lines width and other + /// If the object is result with the color attribute value set, it is used, + /// otherwise the customize is applyed to the object's feature if it is a custom prs + /// \param theObject an object instance + /// \param theFlag a flag of level of customization, which means that only part of sub-elements + /// should be updated(e.g. only highlighted elements) + /// \param theUpdateViewer the parameter whether the viewer should be update immediately + /// \returns true if the object is modified virtual bool customizeObject(ObjectPtr theObject, const ModuleBase_CustomizeFlag& theFlag, const bool theUpdateViewer);