X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;f=src%2FPartSet%2FPartSet_Module.h;h=138ffb3de55b36efdd68503bc2084213ced3b74e;hb=f7a976b98d8cadadcb54a61e42ddb66e00759689;hp=5bd2296297b61616e3f711c588359fa6e0d7bceb;hpb=fce49c1417df9ce5674cc935f6f7f606e007615a;p=modules%2Fshaper.git diff --git a/src/PartSet/PartSet_Module.h b/src/PartSet/PartSet_Module.h index 5bd229629..138ffb3de 100644 --- a/src/PartSet/PartSet_Module.h +++ b/src/PartSet/PartSet_Module.h @@ -52,9 +52,8 @@ public: virtual ~PartSet_Module(); /// Creates custom widgets for property panel - virtual QWidget* createWidgetByType(const std::string& theType, QWidget* theParent, - Config_WidgetAPI* theWidgetApi, std::string theParentId, - QList& theModelWidgets); + virtual ModuleBase_ModelWidget* createWidgetByType(const std::string& theType, QWidget* theParent, + Config_WidgetAPI* theWidgetApi, std::string theParentId); /// Call back forlast tuning of property panel before operation performance virtual void propertyPanelDefined(ModuleBase_Operation* theOperation); @@ -80,6 +79,18 @@ public: /// \param theOperation a stopped operation virtual void operationStopped(ModuleBase_Operation* theOperation); + /// Returns action according to the given ID + /// \param theId an action identifier, it should be uniqued in the bounds of the module + QAction* action(const QString& theId) const; + + /// Returns True if there are available Undos and the sketch manager allows undo + /// \return the boolean result + virtual bool canUndo() const; + + //! Returns True if there are available Redos and the sketch manager allows redo + /// \return the boolean result + virtual bool canRedo() const; + /// Returns whether the object can be displayed at the bounds of the active operation. /// Display only current operation results for usual operation and ask the sketcher manager /// if it is a sketch operation @@ -115,7 +126,6 @@ protected slots: /// It commits the operation of it is can be committed void onOperationActivatedByPreselection(); - protected: /// Register validators for this module virtual void registerValidators(); @@ -123,6 +133,9 @@ protected slots: /// Register selection filters for this module virtual void registerFilters(); + /// Register properties of this module + virtual void registerProperties(); + private slots: /// Processing of vertex selected void onVertexSelected(); @@ -131,29 +144,17 @@ protected slots: /// Breaks sequense of automatically resterted operations void breakOperationSequence(); - /// Check whether the sketch operation is active - /// \return boolean result - bool isSketchOperationActive() const; - - /// Check whether the sketch feature operation is active - /// \return boolean result - bool isSketchFeatureOperationActive() const; - /// Create all actions for context menus. It is called on creation of module /// Put the created actions into an internal map void createActions(); - /// Returns action according to the given ID - /// \param theId an action identifier, it should be uniqued in the bounds of the module - QAction* action(const QString& theId) const; - /// Add action to the internal map /// \param theId - string ID of the item /// \param theAction - action to add void addAction(const QString& theId, QAction* theAction); //! Delete features - void deleteObjects(); + virtual bool deleteObjects(); private: QString myLastOperationId;