From: apo Date: Tue, 7 Mar 2006 09:31:03 +0000 (+0000) Subject: Restore more precise signal detection as in SALOME V2.2.7, connected to Bug PAL11170 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=f95ca7fd11e7b5f0955b62ae265b95511fcf2231;p=modules%2Fsmesh.git Restore more precise signal detection as in SALOME V2.2.7, connected to Bug PAL11170 --- diff --git a/src/OBJECT/Makefile.in b/src/OBJECT/Makefile.in index 3f9abd39d..3d47e38c4 100644 --- a/src/OBJECT/Makefile.in +++ b/src/OBJECT/Makefile.in @@ -78,8 +78,7 @@ LDFLAGS+= \ -lSMESHClient \ -lSalomeApp \ -lSalomeObject \ - -lSMESHControls \ - -lCASCatch + -lSMESHControls LDFLAGSFORBIN += \ -L${GEOM_ROOT_DIR}/lib/salome \ diff --git a/src/SMESH_I/Makefile.in b/src/SMESH_I/Makefile.in index 179743728..c8787fdd3 100644 --- a/src/SMESH_I/Makefile.in +++ b/src/SMESH_I/Makefile.in @@ -74,34 +74,97 @@ LIB_SRC = \ SMESH_Pattern_i.cxx \ SMESH_2smeshpy.cxx -LIB_SERVER_IDL = SMESH_Gen.idl SMESH_Hypothesis.idl SMESH_Mesh.idl \ - SALOME_Component.idl SALOME_Exception.idl \ - SMESH_Filter.idl SMESH_Group.idl SMESH_Pattern.idl - -LIB_CLIENT_IDL = SALOMEDS.idl GEOM_Gen.idl MED.idl SALOMEDS_Attributes.idl SALOME_GenericObj.idl SALOME_Comm.idl +LIB_SERVER_IDL = \ + SMESH_Gen.idl \ + SMESH_Hypothesis.idl \ + SMESH_Mesh.idl \ + SALOME_Component.idl \ + SALOME_Exception.idl \ + SMESH_Filter.idl \ + SMESH_Group.idl \ + SMESH_Pattern.idl + +LIB_CLIENT_IDL = \ + SALOMEDS.idl \ + GEOM_Gen.idl \ + MED.idl \ + SALOMEDS_Attributes.idl \ + SALOME_GenericObj.idl \ + SALOME_Comm.idl # Executables targets BIN = SMESHEngine BIN_SRC = # additionnal information to compil and link file -CPPFLAGS+= $(OCC_INCLUDES) $(HDF5_INCLUDES) -I${KERNEL_ROOT_DIR}/include/salome \ - -I${MED_ROOT_DIR}/include/salome -I${GEOM_ROOT_DIR}/include/salome $(BOOST_CPPFLAGS) -CXXFLAGS+= $(OCC_CXXFLAGS) $(HDF5_INCLUDES) -I${KERNEL_ROOT_DIR}/include/salome \ - -I${MED_ROOT_DIR}/include/salome -I${GEOM_ROOT_DIR}/include/salome - -LDFLAGS+= -L${KERNEL_ROOT_DIR}/lib/salome -lSalomeContainer -lSalomeNS -lRegistry -lSalomeHDFPersist -lSalomeLifeCycleCORBA -lTOOLSDS -lSalomeGenericObj \ - -L${GEOM_ROOT_DIR}/lib/salome -lGEOMClient -lSMESHimpl -lSMESHControls \ - $(OCC_LDPATH) -lTKCDF -lTKBO - - -LDFLAGSFORBIN += -lSMDS -lSMESHDS \ - -L${MED_ROOT_DIR}/lib/salome -lMEDWrapper -lMEDWrapperBase -lMEDWrapper_V2_1 -lMEDWrapper_V2_2 -lmed_V2_1 \ - -lMeshDriver -lMeshDriverMED -lMeshDriverUNV -lMeshDriverDAT -lMeshDriverSTL \ - -L${KERNEL_ROOT_DIR}/lib/salome -lSalomeContainer -lSalomeNS -lRegistry -lSalomeResourcesManager \ - -lOpUtil -lSALOMELocalTrace -lSALOMEBasics -lSalomeNotification -lCASCatch \ - -lSalomeHDFPersist -lSalomeLifeCycleCORBA -lTOOLSDS -lSalomeGenericObj \ - -L${GEOM_ROOT_DIR}/lib/salome -lGEOMClient -lSMESHimpl -lSMESHControls -lNMTTools -lNMTDS \ - $(OCC_LDPATH) -lTKCDF -lTKBO -lTKMath +CPPFLAGS+= \ + $(OCC_INCLUDES) \ + $(HDF5_INCLUDES) \ + $(BOOST_CPPFLAGS) \ + -I${KERNEL_ROOT_DIR}/include/salome \ + -I${MED_ROOT_DIR}/include/salome \ + -I${GEOM_ROOT_DIR}/include/salome + +CXXFLAGS+= \ + $(OCC_CXXFLAGS) \ + $(HDF5_INCLUDES) \ + -I${KERNEL_ROOT_DIR}/include/salome \ + -I${MED_ROOT_DIR}/include/salome \ + -I${GEOM_ROOT_DIR}/include/salome + +LDFLAGS+= \ + -L${KERNEL_ROOT_DIR}/lib/salome \ + -lSalomeContainer \ + -lSalomeNS \ + -lRegistry \ + -lSalomeHDFPersist \ + -lSalomeLifeCycleCORBA \ + -lTOOLSDS \ + -lSalomeGenericObj \ + -L${GEOM_ROOT_DIR}/lib/salome \ + -lGEOMClient \ + -lSMESHimpl \ + -lSMESHControls \ + $(OCC_LDPATH) \ + -lTKCDF \ + -lTKBO + +LDFLAGSFORBIN+= \ + -lSMDS \ + -lSMESHDS \ + -L${MED_ROOT_DIR}/lib/salome \ + -lMEDWrapper \ + -lMEDWrapperBase \ + -lMEDWrapper_V2_1 \ + -lMEDWrapper_V2_2 \ + -lmed_V2_1 \ + -lMeshDriver \ + -lMeshDriverMED \ + -lMeshDriverUNV \ + -lMeshDriverDAT \ + -lMeshDriverSTL \ + -L${KERNEL_ROOT_DIR}/lib/salome \ + -lSalomeContainer \ + -lSalomeNS \ + -lRegistry \ + -lSalomeResourcesManager \ + -lOpUtil \ + -lSALOMELocalTrace \ + -lSALOMEBasics \ + -lSalomeNotification \ + -lSalomeHDFPersist \ + -lSalomeLifeCycleCORBA \ + -lTOOLSDS \ + -lSalomeGenericObj \ + -L${GEOM_ROOT_DIR}/lib/salome \ + -lGEOMClient \ + -lSMESHimpl \ + -lSMESHControls \ + -lNMTTools \ + -lNMTDS \ + $(OCC_LDPATH) \ + -lTKCDF \ + -lTKBO \ + -lTKMath @CONCLUDE@ diff --git a/src/SMESH_I/SMESH_Gen_i.cxx b/src/SMESH_I/SMESH_Gen_i.cxx index 864427fac..e75216c21 100644 --- a/src/SMESH_I/SMESH_Gen_i.cxx +++ b/src/SMESH_I/SMESH_Gen_i.cxx @@ -46,6 +46,7 @@ #include #include #include +#include #include "Utils_CorbaException.hxx" @@ -92,7 +93,6 @@ #include "Utils_ExceptHandlers.hxx" #include -#include using namespace std; using SMESH::TPythonDump; @@ -247,6 +247,8 @@ SMESH_Gen_i::SMESH_Gen_i( CORBA::ORB_ptr orb, myIsEmbeddedMode = false; myShapeReader = NULL; // shape reader mySMESHGen = this; + + OSD::SetSignal( true ); } //============================================================================= @@ -650,7 +652,7 @@ SMESH::SMESH_Mesh_ptr SMESH_Gen_i::CreateMeshesFromUNV( const char* theFileName if(MYDEBUG) MESSAGE( "SMESH_Gen_i::CreateMeshesFromUNV" ); SMESH::SMESH_Mesh_var aMesh = createMesh(); - string aFileName; // = boost::filesystem::path(theFileName).leaf(); + string aFileName; // publish mesh in the study if ( CanPublishInStudy( aMesh ) ) { SALOMEDS::StudyBuilder_var aStudyBuilder = myCurrentStudy->NewBuilder(); @@ -761,7 +763,7 @@ SMESH::SMESH_Mesh_ptr SMESH_Gen_i::CreateMeshesFromSTL( const char* theFileName if(MYDEBUG) MESSAGE( "SMESH_Gen_i::CreateMeshesFromSTL" ); SMESH::SMESH_Mesh_var aMesh = createMesh(); - string aFileName; // = boost::filesystem::path(theFileName).leaf(); + string aFileName; // publish mesh in the study if ( CanPublishInStudy( aMesh ) ) { SALOMEDS::StudyBuilder_var aStudyBuilder = myCurrentStudy->NewBuilder(); diff --git a/src/StdMeshers/Makefile.in b/src/StdMeshers/Makefile.in index d21007816..b38a5dcbf 100644 --- a/src/StdMeshers/Makefile.in +++ b/src/StdMeshers/Makefile.in @@ -91,10 +91,22 @@ BIN = BIN_SRC = # additionnal information to compil and link file -CPPFLAGS+= $(OCC_INCLUDES) -I${KERNEL_ROOT_DIR}/include/salome $(BOOST_CPPFLAGS) -CXXFLAGS+= $(OCC_CXXFLAGS) -I${KERNEL_ROOT_DIR}/include/salome -I${GEOM_ROOT_DIR}/include/salome +CPPFLAGS+= \ + $(OCC_INCLUDES) \ + $(BOOST_CPPFLAGS) \ + -I${KERNEL_ROOT_DIR}/include/salome -LDFLAGS+= -lSMESHimpl -lMEFISTO2D $(OCC_LDPATH) -lTKAdvTools -L${KERNEL_ROOT_DIR}/lib/salome -L${GEOM_ROOT_DIR}/lib/salome \ - -lCASCatch +CXXFLAGS+= \ + $(OCC_CXXFLAGS) \ + -I${KERNEL_ROOT_DIR}/include/salome \ + -I${GEOM_ROOT_DIR}/include/salome + +LDFLAGS+= \ + -lSMESHimpl \ + -lMEFISTO2D \ + $(OCC_LDPATH) \ + -lTKAdvTools \ + -L${KERNEL_ROOT_DIR}/lib/salome \ + -L${GEOM_ROOT_DIR}/lib/salome @CONCLUDE@ diff --git a/src/StdMeshers/StdMeshers_Distribution.cxx b/src/StdMeshers/StdMeshers_Distribution.cxx index 01fc5c6f6..1223fc009 100644 --- a/src/StdMeshers/StdMeshers_Distribution.cxx +++ b/src/StdMeshers/StdMeshers_Distribution.cxx @@ -27,7 +27,7 @@ // $Header$ #include "StdMeshers_Distribution.hxx" -#include "CASCatch_CatchSignals.hxx" +#include "CASCatch.hxx" #include #include @@ -43,8 +43,6 @@ Function::~Function() bool Function::value( const double, double& f ) const { - CASCatch_CatchSignals aCatchSignals; - bool ok = true; if( myConv==0 ) { @@ -170,8 +168,6 @@ FunctionExpr::FunctionExpr( const char* str, const int conv ) myVars( 1, 1 ), myValues( 1, 1 ) { - CASCatch_CatchSignals aCatchSignals; - bool ok = true; CASCatch_TRY { @@ -207,8 +203,6 @@ bool FunctionExpr::value( const double t, double& f ) const if( myExpr.IsNull() ) return false; - CASCatch_CatchSignals aCatchSignals; - ( ( TColStd_Array1OfReal& )myValues ).ChangeValue( 1 ) = t; bool ok = true; CASCatch_TRY { diff --git a/src/StdMeshers/StdMeshers_NumberOfSegments.cxx b/src/StdMeshers/StdMeshers_NumberOfSegments.cxx index b949d872b..ba99cb688 100644 --- a/src/StdMeshers/StdMeshers_NumberOfSegments.cxx +++ b/src/StdMeshers/StdMeshers_NumberOfSegments.cxx @@ -33,7 +33,7 @@ #include "SMESHDS_SubMesh.hxx" #include "SMESH_Mesh.hxx" -#include "CASCatch_CatchSignals.hxx" +#include "CASCatch.hxx" #include #include @@ -212,7 +212,6 @@ void StdMeshers_NumberOfSegments::SetTableFunction(const std::vector& ta double prev = -PRECISION; bool isSame = table.size() == _table.size(); - CASCatch_CatchSignals aCatchSignals; bool pos = false; for (i=0; i < table.size()/2; i++) { double par = table[i*2]; @@ -311,8 +310,6 @@ bool process( const TCollection_AsciiString& str, int convMode, bool& non_neg, bool& non_zero, bool& singulars, double& sing_point ) { - CASCatch_CatchSignals aCatchSignals; - bool parsed_ok = true; Handle( ExprIntrp_GenExp ) myExpr; CASCatch_TRY diff --git a/src/StdMeshersGUI/StdMeshersGUI_DistrPreview.cxx b/src/StdMeshersGUI/StdMeshersGUI_DistrPreview.cxx index 075f2345d..e3ebcd75f 100644 --- a/src/StdMeshersGUI/StdMeshersGUI_DistrPreview.cxx +++ b/src/StdMeshersGUI/StdMeshersGUI_DistrPreview.cxx @@ -1,6 +1,6 @@ #include "StdMeshersGUI_DistrPreview.h" -#include "CASCatch_CatchSignals.hxx" +#include "CASCatch.hxx" #include #include @@ -221,8 +221,6 @@ void StdMeshersGUI_DistrPreview::update() delete[] y; x = y = 0; - CASCatch_CatchSignals aCatchSignals; - CASCatch_TRY { replot(); @@ -267,8 +265,6 @@ bool isCorrectArg( const Handle( Expr_GeneralExpression )& expr ) bool StdMeshersGUI_DistrPreview::init( const QString& str ) { - CASCatch_CatchSignals aCatchSignals; - bool parsed_ok = true; CASCatch_TRY { @@ -311,8 +307,6 @@ double StdMeshersGUI_DistrPreview::calc( bool& ok ) { double res = 0.0; - CASCatch_CatchSignals aCatchSignals; - ok = true; CASCatch_TRY { res = myExpr->Expression()->Evaluate( myVars, myValues ); @@ -333,8 +327,6 @@ bool StdMeshersGUI_DistrPreview::isDone() const bool StdMeshersGUI_DistrPreview::convert( double& v ) const { - CASCatch_CatchSignals aCatchSignals; - bool ok = true; switch( myConv ) {