X-Git-Url: http://git.salome-platform.org/gitweb/?p=modules%2Fsmesh.git;a=blobdiff_plain;f=src%2FSMESHGUI%2FSMESHGUI_Operation.cxx;h=599f87ca1b13f2e91dbe7cd6d38bff93f4ef33e3;hp=bf243ff41f3059102af7cda41a1b74c2902302df;hb=HEAD;hpb=c98d9fcd7f02c1f1f5c24dd3e709ed75228d66c4 diff --git a/src/SMESHGUI/SMESHGUI_Operation.cxx b/src/SMESHGUI/SMESHGUI_Operation.cxx old mode 100755 new mode 100644 index bf243ff41..1e40230db --- a/src/SMESHGUI/SMESHGUI_Operation.cxx +++ b/src/SMESHGUI/SMESHGUI_Operation.cxx @@ -1,4 +1,4 @@ -// Copyright (C) 2007-2016 CEA/DEN, EDF R&D, OPEN CASCADE +// Copyright (C) 2007-2024 CEA, EDF, OPEN CASCADE // // Copyright (C) 2003-2007 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN, // CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS @@ -74,7 +74,7 @@ SMESHGUI* SMESHGUI_Operation::getSMESHGUI() const //======================================================================= // name : startOperation -// Purpose : Start opeartion +// Purpose : Start operation //======================================================================= void SMESHGUI_Operation::startOperation() { @@ -122,7 +122,7 @@ bool SMESHGUI_Operation::isReadyToStart() const tr( "NO_MODULE" ) ); return false; } - else if ( isStudyLocked() ) + else if ( SMESHGUI::isStudyLocked() ) return false; return true; @@ -142,16 +142,6 @@ void SMESHGUI_Operation::setDialogActive( const bool active ) } -//======================================================================= -// name : studyDS -// Purpose : -//======================================================================= -_PTR(Study) SMESHGUI_Operation::studyDS() const -{ - SalomeApp_Study* s = dynamic_cast( study() ); - return s->studyDS(); -} - //======================================================================= // name : onOk // Purpose : @@ -236,30 +226,6 @@ bool SMESHGUI_Operation::isApplyAndClose() const return myIsApplyAndClose; } -/*! - * \brief Verifies whether study of operation is locked - * \param theMess - specifies whether message box must be shown if study is locked - * \return State of study. -* -* Verifies whether study of operation is locked. If second parameter is TRUE and study -* is locked when corresponding message box appears -*/ -bool SMESHGUI_Operation::isStudyLocked( const bool theMess ) const -{ - if ( studyDS() ) - { - if ( studyDS()->GetProperties()->IsLocked() ) - { - if ( theMess ) - SUIT_MessageBox::warning( SMESHGUI::desktop(), tr( "WRN_WARNING" ), - tr( "WRN_STUDY_LOCKED" ) ); - return true; - } - } - - return false; -} - /*! * \brief Verifies whether given operator is valid for this one * \param theOtherOp - other operation @@ -267,7 +233,7 @@ bool SMESHGUI_Operation::isStudyLocked( const bool theMess ) const * * Virtual method redefined from base class verifies whether given operator is valid for * this one (i.e. can be started "above" this operator). In current implementation method -* retuns false if theOtherOp operation is not intended for deleting objects or mesh +* returns false if theOtherOp operation is not intended for deleting objects or mesh * elements. */ bool SMESHGUI_Operation::isValid( SUIT_Operation* theOtherOp ) const