X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;f=src%2FModuleBase%2FModuleBase_Operation.h;h=0fffbc0fdae9bea6f8bfd4fbf3e9678e2b79f2f1;hb=622ac935fd1d8a5bc282ee127666a3e9d1954713;hp=09b6257786cd4c10dcb9d1d5b1f4bcbc1047759a;hpb=03936c76cd52c555961e4636e640c12fe2d47f2f;p=modules%2Fshaper.git diff --git a/src/ModuleBase/ModuleBase_Operation.h b/src/ModuleBase/ModuleBase_Operation.h index 09b625778..0fffbc0fd 100644 --- a/src/ModuleBase/ModuleBase_Operation.h +++ b/src/ModuleBase/ModuleBase_Operation.h @@ -56,6 +56,13 @@ Q_OBJECT /// /returns the instance of the description class ModuleBase_OperationDescription* getDescription() const { return myDescription; } + /// Returns list of granted operation indices + const QStringList& grantedOperationIds() const; + + /// Sets list of operation indices, which can be started without the current operation stop + /// \param theList an ids + void setGrantedOperationIds(const QStringList& theList); + /// Must return true if this operation can be launched as nested for any current operation /// and it is not necessary to check this operation on validity. By default /// the operation is not granted. @@ -83,12 +90,18 @@ Q_OBJECT ModuleBase_IPropertyPanel* propertyPanel() const { return myPropertyPanel; } signals: + /// The operation is started + void beforeStarted(); /// The operation is started void started(); + /// The operation is aborted + void beforeAborted(); /// The operation is aborted void aborted(); + /// The operation is committed + void beforeCommitted(); /// The operation is committed void committed(); @@ -108,7 +121,8 @@ signals: /// to change behavior of operation. There is no point in using this method. It would /// be better to inherit own operator from base one and redefine startOperation method /// instead. - virtual void start(); + /// \return true if the start is successful + virtual bool start(); /// Deactivates current operation which can be resumed later. virtual void postpone(); @@ -168,6 +182,9 @@ private: /// Modified feature flag bool myIsModified; + /// List of operations IDs which are granted of the current operation + QStringList myGrantedIds; + /// Access to property panel ModuleBase_IPropertyPanel* myPropertyPanel; };