X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;f=src%2FModuleBase%2FModuleBase_IModule.h;h=ac70964372e9bc16625a6602e8d3bb868a4fcbbf;hb=8cd56d486b6e96b8814002f9f0f4acadd6cea11b;hp=78e68b5504c49843b810078572d4243d19c06a2a;hpb=cee771b5b59162bd91aa69a3a737a79b1905d866;p=modules%2Fshaper.git diff --git a/src/ModuleBase/ModuleBase_IModule.h b/src/ModuleBase/ModuleBase_IModule.h old mode 100644 new mode 100755 index 78e68b550..ac7096437 --- a/src/ModuleBase/ModuleBase_IModule.h +++ b/src/ModuleBase/ModuleBase_IModule.h @@ -101,6 +101,9 @@ class MODULEBASE_EXPORT ModuleBase_IModule : public QObject return 0; } + /// Returns the active widget, by default it is the property panel active widget + virtual ModuleBase_ModelWidget* activeWidget() const = 0; + /// Returns current workshop ModuleBase_IWorkshop* workshop() const { return myWorkshop; } @@ -191,6 +194,27 @@ class MODULEBASE_EXPORT ModuleBase_IModule : public QObject /// Returns list of granted operation indices virtual void grantedOperationIds(ModuleBase_Operation* theOperation, QStringList& theIds) const; + /// Connects or disconnects to the value changed signal of the property panel widgets + /// \param theWidget a property contol widget + /// \param isToConnect a boolean value whether connect or disconnect + virtual void connectToPropertyPanel(ModuleBase_ModelWidget* theWidget, const bool isToConnect) {}; + + /// Validates the operation to change the "Apply" button state. + /// \param thePreviousState the previous state of the widget + virtual void widgetStateChanged(int thePreviousState) {}; + + /// Returns true if the event is processed. + /// \param thePreviousAttributeID an index of the previous active attribute + virtual bool processEnter(const std::string& thePreviousAttributeID) { return false; }; + + /// Performs some GUI actions after an operation transaction is opened + /// Default realization is empty + virtual void beforeOperationStarted(ModuleBase_Operation* theOperation) {}; + + /// Performs some GUI actions before an operation transaction is stopped + /// Default realization is empty + virtual void beforeOperationStopped(ModuleBase_Operation* theOperation) {}; + signals: /// Signal which is emitted when operation is launched void operationLaunched();