From: mzn Date: Wed, 11 Feb 2009 15:52:43 +0000 (+0000) Subject: Patch provided for bug 0020152 (New tooltip functionality on GUI object browser induc... X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=efb53a0ecdb846804e5b96098df26d171f3474b0;p=modules%2Fgui.git Patch provided for bug 0020152 (New tooltip functionality on GUI object browser induces a crash in YACS). --- diff --git a/src/SalomeApp/SalomeApp_DataObject.cxx b/src/SalomeApp/SalomeApp_DataObject.cxx index 7f31277ae..72fd38592 100644 --- a/src/SalomeApp/SalomeApp_DataObject.cxx +++ b/src/SalomeApp/SalomeApp_DataObject.cxx @@ -33,6 +33,7 @@ #include #include +#include #include #include @@ -263,8 +264,13 @@ QString SalomeApp_DataObject::toolTip( const int /*id*/ ) const SalomeApp_Application* app = dynamic_cast( SUIT_Session::session()->activeApplication() ); if ( app ) { - Engines::Component_var aComponent = - app->lcc()->FindOrLoad_Component( "FactoryServer", componentDataType().toLatin1().constData() ); + // --- try to find (and not load) the component instance, like GEOM instance, + // registered in naming service under Containers//... + // with any container name, on every machine available + Engines::MachineParameters params; + app->lcc()->preSet(params); // --- any container name, anywhere + Engines::Component_var aComponent = + app->lcc()->FindComponent(params, componentDataType().toLatin1().constData() ); if ( !CORBA::is_nil(aComponent) && aComponent->hasObjectInfo() ) { LightApp_RootObject* aRoot = dynamic_cast( root() );