From 63d7200cb5b3da42a26d4e62bd48999477419c39 Mon Sep 17 00:00:00 2001 From: jfa Date: Mon, 13 Mar 2006 15:55:08 +0000 Subject: [PATCH] Join modifications from branch OCC_development_for_3_2_0a2 --- Makefile.in | 2 +- adm_local/Makefile.in | 41 +++++ adm_local/unix/config_files/check_SUPERV.m4 | 53 +++++++ adm_local/unix/make_commence.in | 16 +- build_configure | 11 +- configure.in.base | 20 +++ src/GraphBase/DataFlowBase_DataPort.cxx | 65 +++++--- src/GraphBase/DataFlowBase_XmlHandler.cxx | 21 ++- src/GraphBase/DataFlowBase_XmlHandler.hxx | 1 + .../DataFlowExecutor_InNodeThreads.cxx | 43 +++-- .../DataFlowExecutor_PyDynInvoke.cxx | 22 ++- src/SUPERVGUI/Makefile.in | 2 +- src/SUPERVGUI/SUPERVGUI.cxx | 4 +- src/SUPERVGUI/SUPERVGUI_CanvasControlNode.cxx | 23 +++ src/SUPERVGUI/SUPERVGUI_CanvasControlNode.h | 1 + src/SUPERVGUI/SUPERVGUI_CanvasPort.cxx | 8 + src/SUPERVGUI/SUPERVGUI_CanvasPort.h | 3 + src/SUPERVGUI/SUPERVGUI_Main.cxx | 150 ++++++++++++++++-- src/SUPERVGUI/SUPERVGUI_Main.h | 9 +- src/SUPERVGUI/SUPERV_msg_en.po | 3 + src/Supervision/SuperV_Impl.cxx | 4 +- 21 files changed, 433 insertions(+), 69 deletions(-) create mode 100644 adm_local/Makefile.in create mode 100755 adm_local/unix/config_files/check_SUPERV.m4 diff --git a/Makefile.in b/Makefile.in index 90f03cc..613445c 100644 --- a/Makefile.in +++ b/Makefile.in @@ -14,7 +14,7 @@ VPATH=.:@srcdir@:@top_srcdir@/bin:@top_srcdir@/resources:./bin:@top_srcdir@/idl @COMMENCE@ -SUBDIRS = idl src doc +SUBDIRS = idl src doc adm_local RESOURCES_FILES = \ components.png \ diff --git a/adm_local/Makefile.in b/adm_local/Makefile.in new file mode 100644 index 0000000..9b5e810 --- /dev/null +++ b/adm_local/Makefile.in @@ -0,0 +1,41 @@ +# source path +top_srcdir=@top_srcdir@ +top_builddir=.. +srcdir=@srcdir@ +VPATH=.:$(srcdir)/adm_local + + +all: resources + +install: + cp -rf @top_srcdir@/adm_local @prefix@ + +bin: + +resources : + cp -rf @top_srcdir@/adm_local $(top_builddir) + +inc: + +lib: + +depend: + +depend_idl: + +install-end: + +install-include: + +install-bin: + +uninstall: + +uninstall-idl: + +distclean: + +clean: + +distclean-other: + diff --git a/adm_local/unix/config_files/check_SUPERV.m4 b/adm_local/unix/config_files/check_SUPERV.m4 new file mode 100755 index 0000000..0ac2ba0 --- /dev/null +++ b/adm_local/unix/config_files/check_SUPERV.m4 @@ -0,0 +1,53 @@ +# Check availability of SUPERV module binary distribution +# +# Author : Marc Tajchman (CEA, 2002) +#------------------------------------------------------------ + +AC_DEFUN([CHECK_SUPERV],[ + +AC_CHECKING(for Superv) + +Superv_ok=no + +AC_ARG_WITH(superv, + --with-superv=DIR root directory path of SUPERV installation, + SUPERV_DIR="$withval",SUPERV_DIR="") + +if test "x$SUPERV_DIR" = "x" ; then + +# no --with-gui-dir option used + + if test "x$SUPERV_ROOT_DIR" != "x" ; then + + # SUPERV_ROOT_DIR environment variable defined + SUPERV_DIR=$SUPERV_ROOT_DIR + + else + + # search SUPERV binaries in PATH variable + AC_PATH_PROG(TEMP, libSUPERV.so) + if test "x$TEMP" != "x" ; then + SUPERV_BIN_DIR=`dirname $TEMP` + SUPERV_DIR=`dirname $SUPERV_BIN_DIR` + fi + + fi +# +fi + +if test -f ${SUPERV_DIR}/lib/salome/libSUPERV.so ; then + Superv_ok=yes + AC_MSG_RESULT(Using SUPERV distribution in ${SUPERV_DIR}) + + if test "x$SUPERV_ROOT_DIR" == "x" ; then + SUPERV_ROOT_DIR=${SUPERV_DIR} + fi + AC_SUBST(SUPERV_ROOT_DIR) +else + AC_MSG_WARN("Cannot find compiled SUPERV distribution") +fi + +AC_MSG_RESULT(for SUPERV: $Superv_ok) + +])dnl + diff --git a/adm_local/unix/make_commence.in b/adm_local/unix/make_commence.in index 04d424a..6c4587d 100644 --- a/adm_local/unix/make_commence.in +++ b/adm_local/unix/make_commence.in @@ -252,13 +252,19 @@ $(top_srcdir)/configure.in: $(top_srcdir)/configure.in.base ACLOCAL_SRC = \ -ac_cxx_bool.m4 check_corba.m4 check_vtk.m4 \ +ac_cxx_bool.m4 check_corba.m4 \ ac_cxx_depend_flag.m4 check_hdf5.m4 enable_pthreads.m4 \ ac_cxx_mutable.m4 check_mico.m4 libtool.m4 \ ac_cxx_namespaces.m4 check_omniorb.m4 pyembed.m4 \ -ac_cxx_partial_specialization.m4 check_opengl.m4 python.m4 \ +ac_cxx_partial_specialization.m4 python.m4 \ ac_cxx_typename.m4 check_pthreads.m4 check_cas.m4 \ -ac_cc_warnings.m4 check_qt.m4 check_swig.m4 +ac_cc_warnings.m4 check_swig.m4 -$(top_srcdir)/aclocal.m4: $(ACLOCAL_SRC:%=@KERNEL_ROOT_DIR@/salome_adm/unix/config_files/%) - cd $(top_srcdir) ; aclocal --acdir=adm_local/unix/config_files -I @KERNEL_ROOT_DIR@/salome_adm/unix/config_files +ACLOCAL_GUI = \ +check_vtk.m4 check_opengl.m4 check_qt.m4 \ +check_GUI.m4 check_corba_in_GUI.m4 + +$(top_srcdir)/aclocal.m4: $(ACLOCAL_SRC:%=@KERNEL_ROOT_DIR@/salome_adm/unix/config_files/%) \ + $(ACLOCAL_GUI:%=@GUI_ROOT_DIR@/adm_local/unix/config_files/%) + cd $(top_srcdir) ; aclocal --acdir=adm_local/unix/config_files -I @KERNEL_ROOT_DIR@/salome_adm/unix/config_files \ + -I @GUI_ROOT_DIR@/adm_local/unix/config_files diff --git a/build_configure b/build_configure index 734930e..71e3063 100755 --- a/build_configure +++ b/build_configure @@ -26,6 +26,14 @@ fi # echo "failed : KERNEL_SRC variable is not correct !" # exit #fi +######################################################################## +# Test if the GUI_ROOT_DIR is set correctly + +if test ! -d "${GUI_ROOT_DIR}"; then + echo "failed : GUI_ROOT_DIR variable is not correct !" + exit +fi + ######################################################################## # find_in - utility function # @@ -203,7 +211,8 @@ else echo -n "Creating 'configure' script ... " fi -aclocal --acdir=adm_local/unix/config_files -I ${KERNEL_ROOT_DIR}/salome_adm/unix/config_files +aclocal -I adm_local/unix/config_files -I ${KERNEL_ROOT_DIR}/salome_adm/unix/config_files \ + -I ${GUI_ROOT_DIR}/adm_local/unix/config_files if autoconf then echo "done" diff --git a/configure.in.base b/configure.in.base index 7ec53a5..05fcae2 100644 --- a/configure.in.base +++ b/configure.in.base @@ -258,6 +258,26 @@ echo CHECK_HTML_GENERATORS echo +echo +echo --------------------------------------------- +echo Testing GUI +echo --------------------------------------------- +echo + +CHECK_SALOME_GUI + +echo +echo --------------------------------------------- +echo Testing full GUI +echo --------------------------------------------- +echo + +CHECK_CORBA_IN_GUI +if test "x${CORBA_IN_GUI}" != "xyes"; then + echo "failed : For configure SUPERV module necessary full GUI !" + exit +fi + echo --------------------------------------------- echo Testing Kernel echo --------------------------------------------- diff --git a/src/GraphBase/DataFlowBase_DataPort.cxx b/src/GraphBase/DataFlowBase_DataPort.cxx index 7eb22b1..f559b3c 100644 --- a/src/GraphBase/DataFlowBase_DataPort.cxx +++ b/src/GraphBase/DataFlowBase_DataPort.cxx @@ -91,11 +91,15 @@ void GraphBase::DataPort::InitialValues(CORBA::Any aValue ) { } else if ( !strcmp( Type , "float" ) ) { cdebug << "float" << endl ; - InitialValue <<= (double ) 0. ; + double d = 0.; + InitialValue.replace(CORBA::TypeCode::PR_double_tc(), (void*)(&d)); + //InitialValue <<= (double ) 0. ; } else if ( !strcmp( Type , "double" ) ) { cdebug << "double" << endl ; - InitialValue <<= (double ) 0. ; + double d = 0.; + InitialValue.replace(CORBA::TypeCode::PR_double_tc(), (void*)(&d)); + //InitialValue <<= (double ) 0. ; } else { // Default cdebug << "objref" << endl ; @@ -163,10 +167,11 @@ void GraphBase::DataPort::SetValue( const CORBA::Any * aDataValue ) { #endif } else if ( !strcmp( Type , "float" ) || !strcmp( Type , "double" ) ) { - double d ; - sscanf( t , "%lf" , &d ) ; - *theValue <<= d ; - *theValue >>= d; + double d ; + sscanf( t , "%lf" , &d ) ; + theValue->replace(CORBA::TypeCode::PR_double_tc(), (void*)(&d)); + //*theValue <<= d ; + *theValue >>= d ; #if ValueTrace cdebug << " --> Value( " << d << ") (double) kind " << theValue->type()->kind() ; #endif @@ -190,8 +195,12 @@ void GraphBase::DataPort::SetValue( const CORBA::Any * aDataValue ) { << theValue->type()->kind() ; #endif } - _theValue = theValue ; - *_Value = theValue ; + //_theValue = theValue ; + _theValue = new CORBA::Any( *theValue ) ; + + //*_Value = theValue ; + _Value = &_theValue ; + //JR 21.02.2005 Debug Memory leak : delete aDataValue ; } @@ -226,8 +235,10 @@ void GraphBase::DataPort::SetValue( const CORBA::Any * aDataValue ) { } else if ( !strcmp( Type , "float" ) || !strcmp( Type , "double" ) ) { double d = l ; - *theValue <<= d ; + theValue->replace(CORBA::TypeCode::PR_double_tc(), (void*)(&d)); + //*theValue <<= d ; *theValue >>= d ; + #if ValueTrace cdebug << " --> Value( " << d << ") (double) kind " << theValue->type()->kind() ; #endif @@ -245,8 +256,13 @@ void GraphBase::DataPort::SetValue( const CORBA::Any * aDataValue ) { << theValue->type()->kind() ; #endif } - _theValue = theValue ; - *_Value = theValue ; + + //_theValue = theValue ; + _theValue = new CORBA::Any( *theValue ) ; + + //*_Value = theValue ; + _Value = &_theValue ; + //JR 21.02.2005 Debug Memory leak : delete aDataValue ; } @@ -259,8 +275,12 @@ void GraphBase::DataPort::SetValue( const CORBA::Any * aDataValue ) { cdebug << "Value( " << d << ") (double)"; #endif if ( !strcmp( Type , "float" ) || !strcmp( Type , "double" ) ) { // SuperVision Value - _theValue = aDataValue ; - *_Value = aDataValue ; + //_theValue = aDataValue ; + _theValue = new CORBA::Any( *aDataValue ) ; + + //*_Value = aDataValue ; + _Value = &_theValue ; + *_theValue >>= d; #if ValueTrace cdebug << " == Value( " << d << ") (double)"; @@ -300,8 +320,12 @@ void GraphBase::DataPort::SetValue( const CORBA::Any * aDataValue ) { << theValue->type()->kind() ; #endif } - _theValue = theValue ; - *_Value = theValue ; + //_theValue = theValue ; + _theValue = new CORBA::Any( *theValue ) ; + + //*_Value = theValue ; + _Value = &_theValue ; + //JR 21.02.2005 Debug Memory leak : delete aDataValue ; } @@ -356,14 +380,19 @@ void GraphBase::DataPort::SetValue( const CORBA::Any * aDataValue ) { } else if ( !strcmp( Type , "float" ) || !strcmp( Type , "double" ) ) { double d = (double ) 0. ; - *theValue <<= d ; + theValue->replace(CORBA::TypeCode::PR_double_tc(), (void*)(&d)); + //*theValue <<= d ; *theValue >>= d; #if ValueTrace cdebug << " --> Value( " << d << ") (double) kind " << theValue->type()->kind() ; #endif } - _theValue = theValue ; - *_Value = theValue ; + //_theValue = theValue ; + _theValue = new CORBA::Any( *theValue ) ; + + //*_Value = theValue ; + _Value = &_theValue ; + //JR 21.02.2005 Debug Memory leak : delete aDataValue ; } diff --git a/src/GraphBase/DataFlowBase_XmlHandler.cxx b/src/GraphBase/DataFlowBase_XmlHandler.cxx index 2f22457..8f3a223 100644 --- a/src/GraphBase/DataFlowBase_XmlHandler.cxx +++ b/src/GraphBase/DataFlowBase_XmlHandler.cxx @@ -48,6 +48,8 @@ GraphBase::XmlHandler::XmlHandler( CORBA::ORB_ptr Orb , } VXSize = 0 ; GraphsNumber = 0 ; + + aLinkValue = CORBA::Any(); } GraphBase::XmlHandler::XmlHandler() {} @@ -259,7 +261,12 @@ bool GraphBase::XmlHandler::endElement( const QString&, if ( constructor ) { int sizedata = aListOfDataFlows[ GraphsNumber ].Datas.size() ; aListOfDataFlows[ GraphsNumber ].Datas.resize( sizedata+1 ) ; - aListOfDataFlows[ GraphsNumber ].Datas[ sizedata ] = aLink ; + + if ( aLinkValue.type()->kind() == CORBA::tk_double ) + aLink.aLinkValue = *aLinkDoubleValue ; + + aListOfDataFlows[ GraphsNumber ].Datas[ sizedata ] = aLink ; + if ( VXSize ) { aListOfDataFlows[ GraphsNumber ].Datas[ sizedata ].aListOfCoords.resize( VXSize ) ; int ic ; @@ -719,8 +726,9 @@ bool GraphBase::XmlHandler::endElement( const QString&, break; } case CORBA::tk_double: { - aLink.aLinkValue <<= (double ) 0. ; - double d; + //aLink.aLinkValue <<= (double ) 0. ; + double d = 0.; + aLink.aLinkValue.replace(CORBA::TypeCode::PR_double_tc(), (void*)(&d)); aLink.aLinkValue >>= d; #if TRACE MESSAGE( d << " (double)" ); @@ -776,9 +784,12 @@ bool GraphBase::XmlHandler::endElement( const QString&, case CORBA::tk_double: { double d; sscanf( fieldvalue[depth].c_str() , "%lf" , &d ) ; - aLink.aLinkValue <<= d; + //aLink.aLinkValue <<= d; + aLink.aLinkValue.replace(CORBA::TypeCode::PR_double_tc(), (void*)(&d)); + aLinkValue.replace(CORBA::TypeCode::PR_double_tc(), (void*)(&d)); + aLinkDoubleValue = new CORBA::Any( aLinkValue ); #if TRACE - MESSAGE( d << " (double)" ); + MESSAGE( d << " (double)" ); #endif break; } diff --git a/src/GraphBase/DataFlowBase_XmlHandler.hxx b/src/GraphBase/DataFlowBase_XmlHandler.hxx index b4f3d9e..a5c628b 100755 --- a/src/GraphBase/DataFlowBase_XmlHandler.hxx +++ b/src/GraphBase/DataFlowBase_XmlHandler.hxx @@ -62,6 +62,7 @@ namespace GraphBase { GraphBase::SLink aLink ; // SALOME_SuperVisionBase::ServicesParameterValue aLinkValue ; CORBA::Any aLinkValue ; + CORBA::Any const *aLinkDoubleValue ; int X ; int Y ; int VXSize ; diff --git a/src/GraphExecutor/DataFlowExecutor_InNodeThreads.cxx b/src/GraphExecutor/DataFlowExecutor_InNodeThreads.cxx index 7ff605e..d5bfc53 100644 --- a/src/GraphExecutor/DataFlowExecutor_InNodeThreads.cxx +++ b/src/GraphExecutor/DataFlowExecutor_InNodeThreads.cxx @@ -126,8 +126,9 @@ int GraphExecutor::InNode::SendEvent( const GraphExecutor::NodeEvent anEvent ) { #if SendEventTrace cdebug << pthread_self() << "/" << ThreadNo() << " SendedEvent Node " << Name() << " will exit : a node was aborted ..." << endl ; - State( _NextState ) ; #endif + State( _NextState ) ; + sts = false; } else { sts = executeAction() ; @@ -586,6 +587,7 @@ void GraphExecutor::InNode::ThreadStartAction() { } int GraphExecutor::InNode::executeAction() { + int oldRewindStack = ( _RewindStack > MAXSTACKTHREADSIZE ) ; if ( !CreateNewThread() && oldRewindStack ) { #if ActionsTrace @@ -1406,6 +1408,7 @@ int GraphExecutor::InNode::DataReady_ExecuteAction() { nOutParams = GetNodeOutPortsSize() ; OutParametersList = new ServicesAnyData[nOutParams]; InOutParametersSet( nOutParams , OutParametersList ) ; + #if 0 if ( !Err && IsComputingNode() ) { cdebug << ThreadNo() << " DataReady_ExecuteAction " << Name() << " " @@ -1879,6 +1882,7 @@ int GraphExecutor::InNode::DataReady_ExecuteActionInLineNodes( ServicesAnyData * InLineNode()->PyFuncName() , InParametersList , ServiceInParameter().length() , OutParametersList , ServiceOutParameter().length() ) ; + if ( !StsPyDynInvoke ) { string anErrorMessage = string( "Dynamic Python call for node " ) + string( Name() ) + " function " + @@ -1894,10 +1898,12 @@ int GraphExecutor::InNode::DataReady_ExecuteActionInLineNodes( ServicesAnyData * << InLineNode()->PyFuncName() << "' IsGOTONode PyDynInvoke" << endl ; #endif + StsPyDynInvoke = PyDynInvoke( InLineNode()->PyRunMethod() , InLineNode()->PyFuncName() , InParametersList , ServiceInParameter().length() , OutParametersList , ServiceOutParameter().length() ) ; + if ( !StsPyDynInvoke ) { string anErrorMessage = string( "Dynamic Python call for node " ) + string( Name() ) + " function " + @@ -1913,10 +1919,12 @@ int GraphExecutor::InNode::DataReady_ExecuteActionInLineNodes( ServicesAnyData * << InLineNode()->PyFuncName() << "' IsSwitchNode PyDynInvoke" << endl ; #endif + StsPyDynInvoke = PyDynInvoke( InLineNode()->PyRunMethod() , InLineNode()->PyFuncName() , InParametersList , ServiceInParameter().length() , OutParametersList , ServiceOutParameter().length() ) ; + if ( !StsPyDynInvoke ) { string anErrorMessage = string( "Dynamic Python call for node " ) + string( Name() ) + " function " + @@ -1932,10 +1940,12 @@ int GraphExecutor::InNode::DataReady_ExecuteActionInLineNodes( ServicesAnyData * << InLineNode()->PyFuncName() << "' IsSwitchNode PyDynInvoke" << endl ; #endif + StsPyDynInvoke = PyDynInvoke( InLineNode()->PyRunMethod() , InLineNode()->PyFuncName() , InParametersList , ServiceInParameter().length() + 1 , OutParametersList , ServiceOutParameter().length() + 1 ) ; + if ( !StsPyDynInvoke ) { string anErrorMessage = string( "Dynamic Python call for node " ) + string( Name() ) + " function " + @@ -1980,6 +1990,7 @@ int GraphExecutor::InNode::DataReady_ExecuteActionInLineNodes( ServicesAnyData * else { for ( i = 0 ; i < (int ) ServiceInParameter().length() ; i++ ) { OutParametersList[argout0 + i].Value = InParametersList[argin0 + i].Value ; + #if TraceDataReady_ExecuteAction cdebug << "ArgOut->In" << InParametersList[argin0 + i].Name.c_str() << " " << AnyValue( InParametersList[argin0 + i].Value ) @@ -3258,7 +3269,8 @@ void GraphExecutor::InNode::InParametersSet( bool & Err , double d ; sscanf( t , "%lf" , &d ) ; float f = d ; - D.Value <<= f ; + D.Value.replace(CORBA::TypeCode::PR_float_tc(), (void*)(&f)); +// D.Value <<= f ; #if InParametersSetTrace cdebug << "string '" << t << "' --> " << setw(25) << setprecision(18) << d << " --> float " << " = " << setw(25) << setprecision(18) << f ; @@ -3268,7 +3280,8 @@ void GraphExecutor::InNode::InParametersSet( bool & Err , else if ( !strcmp( Type , "double" ) ) { double d ; sscanf( t , "%lf" , &d ) ; - D.Value <<= d ; + D.Value.replace(CORBA::TypeCode::PR_double_tc(), (void*)(&d)); +// D.Value <<= d ; #if InParametersSetTrace cdebug << "string '" << t << " --> double " << setw(25) << setprecision(18) << d ; #endif @@ -3335,13 +3348,15 @@ void GraphExecutor::InNode::InParametersSet( bool & Err , else if ( !strcmp( Type , "float" ) ) { float f ; f = (float ) l ; - D.Value <<= f ; + D.Value.replace(CORBA::TypeCode::PR_float_tc(), (void*)(&f)); +// D.Value <<= f ; // theOutPort->Value( D.Value ) ; } else if ( !strcmp( Type , "double" ) ) { double d ; d = (double ) l ; - D.Value <<= d ; + D.Value.replace(CORBA::TypeCode::PR_double_tc(), (void*)(&d)); +// D.Value <<= d ; // theOutPort->Value( D.Value ) ; } // else if ( !strcmp( Type , "objref" ) ) { @@ -3395,7 +3410,8 @@ void GraphExecutor::InNode::InParametersSet( bool & Err , else if ( !strcmp( Type , "float" ) ) { float f ; f = (float ) d ; - D.Value <<= f ; + D.Value.replace(CORBA::TypeCode::PR_float_tc(), (void*)(&f)); +// D.Value <<= f ; // theOutPort->Value( D.Value ) ; } else if ( !strcmp( Type , "double" ) ) { @@ -3455,12 +3471,14 @@ void GraphExecutor::InNode::InParametersSet( bool & Err , } else if ( !strcmp( Type , "float" ) ) { float f = 0 ; - D.Value <<= f ; + D.Value.replace(CORBA::TypeCode::PR_float_tc(), (void*)(&f)); +// D.Value <<= f ; // theOutPort->Value( D.Value ) ; } else if ( !strcmp( Type , "double" ) ) { double d = 0 ; - D.Value <<= d ; + D.Value.replace(CORBA::TypeCode::PR_double_tc(), (void*)(&d)); +// D.Value <<= d ; // theOutPort->Value( D.Value ) ; } // else if ( !strcmp( Type , "objref" ) ) { @@ -3548,11 +3566,13 @@ void GraphExecutor::InNode::InOutParametersSet( int nOutParams , } else if ( !strcmp( Type , "float" ) ) { float f = 0 ; - D.Value <<= f ; + D.Value.replace(CORBA::TypeCode::PR_float_tc(), (void*)(&f)); +// D.Value <<= f ; } else if ( !strcmp( Type , "double" ) ) { double d = 0 ; - D.Value <<= d ; + D.Value.replace(CORBA::TypeCode::PR_double_tc(), (void*)(&d)); +// D.Value <<= d ; } else { D.Value <<= CORBA::Object::_nil() ; @@ -3698,7 +3718,8 @@ bool GraphExecutor::InNode::OutParametersSet( bool Err , float f; D.Value >>= f; double d = (double ) f ; - D.Value <<= d ; + D.Value.replace(CORBA::TypeCode::PR_double_tc(), (void*)(&d)); +// D.Value <<= d ; #if OutParametersSetTrace cdebug << ThreadNo() << " " << f << "(float)" << endl ; #endif diff --git a/src/GraphExecutor/DataFlowExecutor_PyDynInvoke.cxx b/src/GraphExecutor/DataFlowExecutor_PyDynInvoke.cxx index 85fc431..68211da 100644 --- a/src/GraphExecutor/DataFlowExecutor_PyDynInvoke.cxx +++ b/src/GraphExecutor/DataFlowExecutor_PyDynInvoke.cxx @@ -392,8 +392,12 @@ bool GraphExecutor::InNode::PyDynInvoke( PyObject * MyPyRunMethod , ArgValue = Py_BuildValue( "O" , ResultObj ) ; PyTuple_SetItem( ArgsList , i , ArgValue ) ; #if PyDynInvokeTrace - cdebug << "ArgIn" << i << " : " << sname << " " << method << " Value (objref) ArgsList->ob_refcnt" - << ArgsList->ob_refcnt << " ArgValue->ob_refcnt" << ArgValue->ob_refcnt << endl ; + if ( ArgValue ) + cdebug << "ArgIn" << i << " : " << sname << " " << method << " Value (objref) ArgsList->ob_refcnt" + << ArgsList->ob_refcnt << " ArgValue->ob_refcnt" << ArgValue->ob_refcnt << endl ; + else + cdebug << "ArgIn" << i << " : " << sname << " " << method << " Value (objref) ArgsList->ob_refcnt" + << ArgsList->ob_refcnt << " ArgValue is NULL" << endl ; cdebug << "MyPyObjRefList->ob_refcnt " << MyPyObjRefList->ob_refcnt-1 << endl ; #endif Py_DECREF( MyPyObjRefList ) ; @@ -402,9 +406,13 @@ bool GraphExecutor::InNode::PyDynInvoke( PyObject * MyPyRunMethod , } else { #if PyDynInvokeTrace - cdebug << "ResultObj->ob_refcnt " << ResultObj->ob_refcnt-1 << endl ; + if ( ResultObj ) + cdebug << "ResultObj->ob_refcnt " << ResultObj->ob_refcnt-1 << endl ; + else + cdebug << "ResultObj is NULL" << endl ; #endif - Py_DECREF( ResultObj ) ; + if ( ResultObj ) + Py_DECREF( ResultObj ) ; } break ; } @@ -573,7 +581,8 @@ bool GraphExecutor::InNode::PyDynInvoke( PyObject * MyPyRunMethod , else { f = PyFloat_AsDouble( ArgValue ) ; } - data <<= f ; + data.replace(CORBA::TypeCode::PR_float_tc(), (void*)(&f)); + //data <<= f ; #if PyDynInvokeTrace cdebug << "ArgOut" << i << " : " << sname << " " << method << " Value " << f << " (float)" << " Result->ob_refcnt" << Result->ob_refcnt << " ArgValue->ob_refcnt" @@ -597,7 +606,8 @@ bool GraphExecutor::InNode::PyDynInvoke( PyObject * MyPyRunMethod , else { d = PyFloat_AsDouble( ArgValue ) ; } - data <<= d ; + data.replace(CORBA::TypeCode::PR_double_tc(), (void*)(&d)); + //data <<= d ; #if PyDynInvokeTrace cdebug << "ArgOut" << i << " : " << sname << " " << method << " Value " << d << " (double)" << " Result->ob_refcnt" << Result->ob_refcnt << " ArgValue->ob_refcnt" diff --git a/src/SUPERVGUI/Makefile.in b/src/SUPERVGUI/Makefile.in index 465b18d..207a757 100644 --- a/src/SUPERVGUI/Makefile.in +++ b/src/SUPERVGUI/Makefile.in @@ -103,7 +103,7 @@ CPPFLAGS+=$(QT_INCLUDES) $(PYTHON_INCLUDES) $(OCC_INCLUDES) $(VTK_INCLUDES) $(OG LDFLAGS+=$(PYTHON_LIBS) $(QT_MT_LIBS) $(VTK_LIBS) $(OGL_LIBS) \ -lSalomeApp -lsuit -lSalomeNS -lEvent \ -lSalomeLifeCycleCORBA -lSalomeNotification -lSUPERVGraph \ - -L${KERNEL_ROOT_DIR}/lib/salome -L${GUI_ROOT_DIR}/lib/salome + -L${KERNEL_ROOT_DIR}/lib/salome -lSalomeDS -lSalomeDSClient -L${GUI_ROOT_DIR}/lib/salome #-lqsplitterP LIBS+= diff --git a/src/SUPERVGUI/SUPERVGUI.cxx b/src/SUPERVGUI/SUPERVGUI.cxx index 4f75dfb..2442a96 100644 --- a/src/SUPERVGUI/SUPERVGUI.cxx +++ b/src/SUPERVGUI/SUPERVGUI.cxx @@ -692,8 +692,8 @@ bool SUPERVGUI::createDataflow( const NEW_DF_MODE mode, bool theInitialDF ) { else myInitialViewFrame = aViewFrame; } - else - registerGraph( f, main ); + // mkr : IPAL11550 : register graph not depend on creation mode + registerGraph( f, main ); main->resizeView( new QResizeEvent( aViewFrame->size(), aViewFrame->size() ) ); aViewFrame->show(); QFileInfo inf( f ); diff --git a/src/SUPERVGUI/SUPERVGUI_CanvasControlNode.cxx b/src/SUPERVGUI/SUPERVGUI_CanvasControlNode.cxx index 0ceb073..ca77bd9 100644 --- a/src/SUPERVGUI/SUPERVGUI_CanvasControlNode.cxx +++ b/src/SUPERVGUI/SUPERVGUI_CanvasControlNode.cxx @@ -301,6 +301,29 @@ void SUPERVGUI_CanvasMacroNode::exportDataflow() } } +// mkr : IPAL11549 : before remove Macro Node we have to destroy +// all its opened sub-graphs +void SUPERVGUI_CanvasMacroNode::remove() +{ + SUPERV_Graph aGraph; + if (getEngine()->IsMacro()) { + SUPERV_Graph aMacro = getMacroNode(); + if (aMacro->IsStreamMacro()) + aGraph = aMacro->StreamObjRef(); + else + aGraph = aMacro->FlowObjRef(); + } + if (SUPERV_isNull(aGraph)) { + QMessageBox::warning(SUIT_Session::session()->activeApplication()->desktop(), tr("WARNING"), tr("MSG_NOSUBGRAPH_TO_REMOVE")); + return; + } + else { + getMain()->destroySubGraph(aGraph->Name()); + } + + SUPERVGUI_CanvasNode::remove(); +} + //===================================================================== // Cell node: node for table view //===================================================================== diff --git a/src/SUPERVGUI/SUPERVGUI_CanvasControlNode.h b/src/SUPERVGUI/SUPERVGUI_CanvasControlNode.h index cd43afa..6094841 100644 --- a/src/SUPERVGUI/SUPERVGUI_CanvasControlNode.h +++ b/src/SUPERVGUI/SUPERVGUI_CanvasControlNode.h @@ -34,6 +34,7 @@ class SUPERVGUI_CanvasMacroNode : public SUPERVGUI_CanvasComputeNode { virtual QPopupMenu* getPopupMenu(QWidget* theParent); public slots: + virtual void remove(); // mkr : IPAL11549 void openSubGraph(); void exportDataflow(); diff --git a/src/SUPERVGUI/SUPERVGUI_CanvasPort.cxx b/src/SUPERVGUI/SUPERVGUI_CanvasPort.cxx index 2b8b0f5..b690092 100644 --- a/src/SUPERVGUI/SUPERVGUI_CanvasPort.cxx +++ b/src/SUPERVGUI/SUPERVGUI_CanvasPort.cxx @@ -259,6 +259,9 @@ SUPERVGUI_CanvasPortOut::SUPERVGUI_CanvasPortOut(QObject* theParent, SUPERVGUI_M { Trace("SUPERVGUI_CanvasPortOut::SUPERVGUI_CanvasPortOut"); myInStudy = false; + + // mkr : PAL8150 + connect(this, SIGNAL(putInStudy( QString* )), getMain(), SLOT(onPutInStudy( QString* ))); } SUPERVGUI_CanvasPortOut::~SUPERVGUI_CanvasPortOut() @@ -321,6 +324,11 @@ void SUPERVGUI_CanvasPortOut::toStudy() aSupMod->unregisterGraph(getMain()); aSupMod->registerGraph(getMain()->getDataflow()->getIOR(), getMain()); } + + // mkr : PAL8150 + QString aNodePortName = QString( getEngine()->Node()->Name() ) + QString( "_" ) + QString( getEngine()->Name() ); + emit putInStudy( &aNodePortName ); + } diff --git a/src/SUPERVGUI/SUPERVGUI_CanvasPort.h b/src/SUPERVGUI/SUPERVGUI_CanvasPort.h index 6ed5f5d..e218d57 100644 --- a/src/SUPERVGUI/SUPERVGUI_CanvasPort.h +++ b/src/SUPERVGUI/SUPERVGUI_CanvasPort.h @@ -97,6 +97,9 @@ class SUPERVGUI_CanvasPortOut : public SUPERVGUI_CanvasPort { virtual QPopupMenu* getPopupMenu(QWidget* theParent); + signals: + void putInStudy( QString* ); // mkr : PAL8150 + public slots: void toStudy(); diff --git a/src/SUPERVGUI/SUPERVGUI_Main.cxx b/src/SUPERVGUI/SUPERVGUI_Main.cxx index 49c4b88..e9160aa 100644 --- a/src/SUPERVGUI/SUPERVGUI_Main.cxx +++ b/src/SUPERVGUI/SUPERVGUI_Main.cxx @@ -65,6 +65,20 @@ #include using namespace boost; +// mkr : PAL8150 +#define SYNCPUTINSTUDY(NodesName) \ + for ( int n = 0; n < nodes->NodesName.length(); n++ ) { \ + SUPERV_CNode aCNode = SUPERV::CNode::_narrow(nodes->NodesName[n]); \ + SUPERV_Ports aPortList = aCNode->Ports(); \ + for (int p = 0; p < aPortList->length(); p++) { \ + SUPERV::Port_ptr aPort = aPortList[p].in(); \ + if ( !aPort->IsInput() && !aPort->IsGate() ) { \ + bool aInStudy = dynamic_cast( aMain->getCanvas()->getPort(aPort) )->isInStudy(); \ + dynamic_cast( getCanvas()->getPort( getDataflow()->Node(aCNode->Name())->Port(aPort->Name()) ) )->setStudyState(aInStudy); \ + } \ + } \ + } + SUPERVGUI_Main::SUPERVGUI_Main( SUPERVGraph_ViewFrame* theParent, SUIT_Desktop* theDesktop, SUPERV_Graph theDataFlow ) : SUPERVGraph_View(theParent), @@ -88,6 +102,9 @@ SUPERVGUI_Main::SUPERVGUI_Main( SUPERVGraph_ViewFrame* theParent, } else { init(theDesktop); } + + syncPutInStudy(); // mkr : PAL8150 + // mkr : IPAL11362 connect(this, SIGNAL(EventToSync()), this, SLOT(onObjectCreatedDeleted())); } @@ -168,7 +185,7 @@ void SUPERVGUI_Main::init(SUIT_Desktop* theDesktop) { sync(); show(); - if ( myLogged && !myLogFileName.isEmpty() && QFile::exists( myLogFileName ) ) { + if ( myLogged && !myLogFileName.isEmpty() /*&& QFile::exists( myLogFileName )*/ ) { // mkr : PAL7037 myLogFile = fopen( myLogFileName.latin1(), "a" ); if ( myLogFile == NULL ) myLogged = false; @@ -194,7 +211,7 @@ SUPERVGUI_Main::~SUPERVGUI_Main() { SUIT_ViewManager* aVM = it.data()->getViewManager(); STD_Application* anApp = dynamic_cast( SUIT_Session::session()->activeApplication() ); if ( anApp ) anApp->removeViewManager(aVM); - if ( aVM ) delete aVM; + //if ( aVM ) delete aVM; // mkr : IPAL11547 } mySubGraphs.clear(); @@ -246,7 +263,7 @@ void SUPERVGUI_Main::filterNotification() { fclose( myLogFile ); } myLogFile = NULL; - if ( myLogged && !myLogFileName.isEmpty() && QFile::exists( myLogFileName ) ) { + if ( myLogged && !myLogFileName.isEmpty() /*&& QFile::exists( myLogFileName )*/ ) { // mkr : PAL7037 myLogFile = fopen( myLogFileName.latin1(), "a" ); if ( myLogFile == NULL ) { myLogged = false; @@ -489,9 +506,9 @@ void SUPERVGUI_Main::openSubGraph(SUPERV_CNode theNode, bool correct) if ( aStudyFrame ) { SUPERVGraph_ViewFrame* aViewFrame = dynamic_cast( aStudyFrame ); if( aViewFrame ) { - /*SUPERVGUI_Main* m = */new SUPERVGUI_Main(aViewFrame, - aSupMod->application()->desktop(),//getDesktop(), - aGraph); + new SUPERVGUI_Main(aViewFrame, + aSupMod->application()->desktop(),//getDesktop(), + aGraph); // connect(aStudyFrame, SIGNAL(sfStudyFrameClosing(QAD_StudyFrame*)), // this, SLOT(onSubGraphClosed(QAD_StudyFrame*))); connect(aSupMod->application()->desktop(), SIGNAL(windowActivated( SUIT_ViewWindow* )), @@ -510,6 +527,18 @@ void SUPERVGUI_Main::openSubGraph(SUPERV_CNode theNode, bool correct) } } +// mkr : IPAL11549 +void SUPERVGUI_Main::destroySubGraph(QString theSubGraphName) +{ + if ( mySubGraphs.contains(theSubGraphName) ) { + SUIT_ViewWindow* aStudyFrame = mySubGraphs[theSubGraphName]; + onSubGraphClosed(aStudyFrame); + SUIT_ViewManager* aVM = aStudyFrame->getViewManager(); + STD_Application* anApp = dynamic_cast( SUIT_Session::session()->activeApplication() ); + if ( anApp ) anApp->removeViewManager(aVM); + } +} + bool SUPERVGUI_Main::eventFilter( QObject* o, QEvent* e) { // workaround to get close event @@ -580,7 +609,9 @@ void SUPERVGUI_Main::onObjectCreatedDeleted() if ( aMainList->count() == 1 ) { SUPERVGUI_Main* aMain = dynamic_cast( aMainList->first() ); if ( aMain ) - if ( !QString(aMain->getDataflow()->getIOR()).compare(getDataflow()->getIOR()) // equal dataflows + if ( !CORBA::is_nil( aMain->getDataflow() ) + && + !QString(aMain->getDataflow()->getIOR()).compare(getDataflow()->getIOR()) // equal dataflows && aMain != this ) // not equal mains aMain->getCanvas()->merge(); @@ -591,6 +622,84 @@ void SUPERVGUI_Main::onObjectCreatedDeleted() } } +// mkr : PAL8150 : synchronize many views of the same dataflow ("Put In Study"/"Not In Study" operation) +void SUPERVGUI_Main::onPutInStudy( QString* theNodePortName ) +{ + if ( study ) { + if ( STD_Application* app = dynamic_cast( study->application() ) ) { + ViewManagerList aVMList; + app->viewManagers( SUPERVGraph_Viewer::Type(), aVMList ); + SUIT_ViewManager* aVM; + for ( aVM = aVMList.first(); aVM; aVM = aVMList.next() ) { + QPtrVector aVWList = aVM->getViews(); + for ( int i = 0; i < aVWList.count(); i++ ) { + SUPERVGraph_ViewFrame* aVW = dynamic_cast( aVWList[i] ); + QObjectList* aMainList = aVW->queryList("SUPERVGUI_Main"); + if ( aMainList->count() == 1 ) { + SUPERVGUI_Main* aMain = dynamic_cast( aMainList->first() ); + if ( aMain ) + if ( !QString(aMain->getDataflow()->getIOR()).compare(getDataflow()->getIOR()) // equal dataflows + && + aMain != this ) { // not equal mains + QString aNodeName = theNodePortName->left( theNodePortName->find('_') ); + QString aPortName = theNodePortName->right( theNodePortName->length() - theNodePortName->find('_') - 1 ); + bool anIsInStudy = dynamic_cast( getCanvas()->getPort( getDataflow()->Node( aNodeName )->GetOutPort( aPortName ) ) )->isInStudy(); + dynamic_cast( aMain->getCanvas()->getPort( aMain->getDataflow()->Node( aNodeName )->GetOutPort( aPortName ) ) )->setStudyState( anIsInStudy ); + } + } + } + } + } + } +} + +// mkr : PAL8150 : synchronize many views of the same dataflow ("Display" operation for dataflow) +void SUPERVGUI_Main::syncPutInStudy() +{ + if ( study ) { + if ( STD_Application* app = dynamic_cast( study->application() ) ) { + ViewManagerList aVMList; + app->viewManagers( SUPERVGraph_Viewer::Type(), aVMList ); + SUIT_ViewManager* aVM; + for ( aVM = aVMList.first(); aVM; aVM = aVMList.next() ) { + QPtrVector aVWList = aVM->getViews(); + for ( int i = 0; i < aVWList.count(); i++ ) { + SUPERVGraph_ViewFrame* aVW = dynamic_cast( aVWList[i] ); + QObjectList* aMainList = aVW->queryList("SUPERVGUI_Main"); + if ( aMainList->count() == 1 ) { + SUPERVGUI_Main* aMain = dynamic_cast( aMainList->first() ); + if ( aMain ) + if ( !CORBA::is_nil( aMain->getDataflow() ) + && + !QString(aMain->getDataflow()->getIOR()).compare(getDataflow()->getIOR()) // equal dataflows + && + aMain != this ) { // not equal mains + + // check "myInStudy" field of output ports of original main (i.e. this main) + // and synchronize this property for nodes' output ports of dublicate main (i.e. of aMain) + SUPERV_Nodes nodes = aMain->getDataflow()->Nodes(); + + SYNCPUTINSTUDY(CNodes); + SYNCPUTINSTUDY(FNodes); + SYNCPUTINSTUDY(INodes); + SYNCPUTINSTUDY(GNodes); + SYNCPUTINSTUDY(LNodes); + SYNCPUTINSTUDY(ELNodes); + SYNCPUTINSTUDY(SNodes); + SYNCPUTINSTUDY(ESNodes); + SYNCPUTINSTUDY(Graphs); + + setRunTime( aMain->getRunTime() ); + + break; + } + } + } + } + } + } +} + void SUPERVGUI_Main::run( const bool andSuspend ) { Trace("SUPERVGUI_Main::run"); if ( SUPERV_isNull(dataflow) ) @@ -654,6 +763,7 @@ void SUPERVGUI_Main::kill() { void SUPERVGUI_Main::suspendResume() { Trace("SUPERVGUI_Main::suspendResume"); + if ((SUPERV_isNull(dataflow))) return; if (dataflow->IsEditing()) { @@ -913,7 +1023,7 @@ _PTR(SObject) SearchOrCreateSOWithName( _PTR(Study) const theStudy, _PTR(ChildIterator) anIterator ( theStudy->NewChildIterator(theSO) ); for (; anIterator->More(); anIterator->Next()) { if (anIterator->Value()->FindAttribute(anAttr, "AttributeName")) { - aName = anAttr; + aName = _PTR(AttributeName) ( anAttr ); if (strcmp(aName->Value().c_str(), theName) == 0) { aResult = anIterator->Value(); break; @@ -929,7 +1039,7 @@ _PTR(SObject) SearchOrCreateSOWithName( _PTR(Study) const theStudy, // add new SObject aResult = theBuilder->NewObject( theSO ); anAttr = theBuilder->FindOrCreateAttribute(aResult, "AttributeName"); - aName = anAttr; + aName = _PTR(AttributeName) ( anAttr ); aName->SetValue(theName); return aResult; } @@ -963,7 +1073,7 @@ _PTR(SObject) createDataflowSObj( SUIT_Study* study, if ( !aComponent ) { // is supervision component not found, then create it aComponent = aBuilder->NewComponent(STUDY_SUPERVISION); anAttr = aBuilder->FindOrCreateAttribute(aComponent, "AttributeName"); - aName = anAttr; + aName = _PTR(AttributeName) ( anAttr ); aName->SetValue( (( CAM_Application* )(study->application()))->moduleTitle( "SUPERV" ).latin1() ); anAttr = aBuilder->FindOrCreateAttribute(aComponent, "AttributePixMap"); @@ -980,7 +1090,7 @@ _PTR(SObject) createDataflowSObj( SUIT_Study* study, // create dataflow SObject ("aNewDataflow_1") aSO = aBuilder->NewObject(aComponent); anAttr = aBuilder->FindOrCreateAttribute(aSO, "AttributeName"); - aName = anAttr; + aName = _PTR(AttributeName) ( anAttr ); aName->SetValue(dataflow->Name()); anAttr = aBuilder->FindOrCreateAttribute(aSO, "AttributeIOR"); _PTR(AttributeIOR) anIORAttr ( anAttr ); @@ -1194,16 +1304,16 @@ void SUPERVGUI_Main::syncNotification() { long counter; char* date; long stamp; - + while (notification->Receive(&graph, &node, &type, &message, &sender, &counter, &date, &stamp)) { -// if (isFiltered(graph, node, type, message, sender, counter, date, stamp)) { + if (isFiltered(graph, node, type, message, sender, counter, date, stamp)) { // mkr : PAL7037 QString mess(""); mess += "NOTIF: "; mess += graph; mess += " / " ; mess += node; mess += " / " ; mess += type; mess += " / " ; mess += message; getMessage()->putMessage(mess.latin1()); -// }; + }; }; } @@ -1213,7 +1323,13 @@ bool SUPERVGUI_Main::isFiltered(char* graph, char* node, char* type, char* me bool b = false; if (strcmp(getDataflow()->Name(), graph) == 0) { SUPERVGUI_CanvasNode* n; - QObjectList* nodes = queryList("SUPERVGUI_CanvasNode"); + QObjectList* nodes; + // mkr : PAL7037 --> + if (myCurrentView == CANVASTABLE) + nodes = myArray->queryList("SUPERVGUI_CanvasNode"); + else + nodes = myCanvas->queryList("SUPERVGUI_CanvasNode"); + // mkr : PAL7037 <-- QObjectListIt i(*nodes); while ((n=(SUPERVGUI_CanvasNode*)i.current()) != 0) { ++i; @@ -1503,10 +1619,10 @@ void SUPERVGUI_Thread::run() SUPERV_CNode aNode = NULL; SUPERV::GraphEvent aEvent = SUPERV::UndefinedEvent ; SUPERV::GraphState aState = SUPERV::UndefinedState ; - + // blocking function of Engine. Return from there only after anEvent happens on node aNode myMain->getDataflow()->Event(aNode, aEvent, aState); - + ProcessVoidEvent( new TMainRunEvent( this, &SUPERVGUI_Thread::main_thread_run,aNode, aEvent, aState ) ); } // end of while( myIsActive ) diff --git a/src/SUPERVGUI/SUPERVGUI_Main.h b/src/SUPERVGUI/SUPERVGUI_Main.h index 146c90f..a6a6ac8 100644 --- a/src/SUPERVGUI/SUPERVGUI_Main.h +++ b/src/SUPERVGUI/SUPERVGUI_Main.h @@ -64,6 +64,7 @@ class SUPERVGUI_Main: public SUPERVGraph_View { void suspendResume(); //void stopRestart(); void openSubGraph(SUPERV_CNode theNode, bool correct = false); + void destroySubGraph(QString theSubGraphName); // mkr : IPAL11549 bool putDataStudy(SUPERV_Port port, const char* inout); @@ -135,6 +136,10 @@ class SUPERVGUI_Main: public SUPERVGraph_View { virtual void resizeView( QResizeEvent* theEvent ); + // mkr : PAL8150 + void setRunTime( QDateTime theRunTime ) { myRunTime = theRunTime; } + QDateTime getRunTime() const { return myRunTime; } + signals: void KillMyThread(bool theValue); void EventToSync(); // mkr : IPAL11362 @@ -161,6 +166,7 @@ class SUPERVGUI_Main: public SUPERVGraph_View { void onShowToolbar(); void onObjectCreatedDeleted(); // mkr : PAL8237 + void onPutInStudy( QString* ); // mkr : PAL8150 private slots: void chooseData(QListViewItem* item); @@ -171,7 +177,8 @@ class SUPERVGUI_Main: public SUPERVGraph_View { void syncNotification(); bool isFiltered(char* graph, char* node, char* type, char* message, char* sender, long counter, char* date, long stamp); void closeEvent(QCloseEvent*); - + void syncPutInStudy(); // mkr : PAL8150 + SUPERV_Graph dataflow; QMap mySubGraphs; diff --git a/src/SUPERVGUI/SUPERV_msg_en.po b/src/SUPERVGUI/SUPERV_msg_en.po index 95ee79d..b729f5d 100644 --- a/src/SUPERVGUI/SUPERV_msg_en.po +++ b/src/SUPERVGUI/SUPERV_msg_en.po @@ -420,6 +420,9 @@ msgstr "No Supervisor Window Has Been Selected to add new components" msgid "MSG_NOWINDOW_TO_EXPORT" msgstr "No Supervisor Window Has Been Selected to Export a Dataflow" +msgid "MSG_NOSUBGRAPH_TO_REMOVE" +msgstr "There is no sub-graph of this Macro node to remove" + msgid "MSG_CANT_LOAD_SUPERV" msgstr "Cannot Find or Load Supervisor Component" diff --git a/src/Supervision/SuperV_Impl.cxx b/src/Supervision/SuperV_Impl.cxx index 6806ada..98a78ae 100644 --- a/src/Supervision/SuperV_Impl.cxx +++ b/src/Supervision/SuperV_Impl.cxx @@ -712,7 +712,9 @@ SUPERV::Value_ptr SuperV_Impl::StringValue( const char * aStrIOR ) { // return(anAny); } } - catch ( CORBA::BAD_PARAM ) { + catch ( ... ) { // mkr : catch any exception to avoid crash after set incorrect + // value of 'objref' type for input port + //catch ( CORBA::BAD_PARAM ) { // JR : objref or string only ==> the eventual convertion to long or double is done in // the SuperVisionEngine with the real type of the argument -- 2.39.2