X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;f=src%2FXGUI%2FXGUI_Workshop.h;h=37c04437fdc18426d5a0527af068e7ae500853ce;hb=52a2aa0728f8694d5774a20bd1eeba8e5e2f8b27;hp=c2b067741db3bb8162dd48b7565ab87046036251;hpb=a24b7e6f4d112d5e7889fd76f030298fc428cd01;p=modules%2Fshaper.git diff --git a/src/XGUI/XGUI_Workshop.h b/src/XGUI/XGUI_Workshop.h index c2b067741..37c04437f 100644 --- a/src/XGUI/XGUI_Workshop.h +++ b/src/XGUI/XGUI_Workshop.h @@ -164,7 +164,7 @@ Q_OBJECT void activatePart(std::shared_ptr theFeature); //! Delete features - void deleteObjects(const QObjectPtrList& theList); + void deleteObjects(); //! Returns true if there is at least one selected body/construction/group result //! \return boolean value @@ -213,6 +213,19 @@ Q_OBJECT */ bool isActiveOperationAborted(); + //! Delete features. Delete the referenced features. There can be a question with a list of referenced + //! objects. + //! \param theList an objects to be deleted + //! \param theIgnoredFeatures a list of features to be ignored during delete + //! \param theParent a parent widget for the question message box + //! \param theAskAboutDeleteReferences if true, the message box with a list of references to the + //! objects features appear. If the user chose do not continue, the deletion is not performed + //! \return the success of the delete + static bool deleteFeatures(const QObjectPtrList& theList, + std::set theIgnoredFeatures = std::set(), + QWidget* theParent = 0, + const bool theAskAboutDeleteReferences = false); + signals: /// Emitted when selection happens in Salome viewer void salomeViewerSelection(); @@ -391,7 +404,10 @@ signals: void createDockWidgets(); /// Displaus object and fit all viewer if the object is first (update viewer will not be called) - void displayObject(ObjectPtr theObj); + /// Asks the module whether the object can be displayed + /// \param theObj an object + /// \return true if the object is displayed + bool displayObject(ObjectPtr theObj); //! Extends undo/redo toolbutton's with history menu //! \param theObject - in the OpenParts it is a QToolButton by itself, @@ -425,6 +441,9 @@ private: // Flag to check that part document is in process of activating bool myPartActivating; + + /// The flag is true when we loading a document + bool myIsLoadingData; }; #endif