From: vsr Date: Wed, 26 Jan 2011 09:47:50 +0000 (+0000) Subject: Fix observers bug: crash application (SIGSEGV) on Dump Python operation in the re... X-Git-Tag: V6_3_0a1~80 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=6485f419dbba6a9f3c8c6e80225e035db4ea446e;p=modules%2Fgui.git Fix observers bug: crash application (SIGSEGV) on Dump Python operation in the re-opened (non-empty) study --- diff --git a/src/SalomeApp/SalomeApp_Application.cxx b/src/SalomeApp/SalomeApp_Application.cxx index 1525e1b10..51f08e2fd 100644 --- a/src/SalomeApp/SalomeApp_Application.cxx +++ b/src/SalomeApp/SalomeApp_Application.cxx @@ -1285,9 +1285,11 @@ void SalomeApp_Application::updateObjectBrowser( const bool updateModels ) { _PTR(SComponent) aComponent ( it->Value() ); +#ifndef WITH_SALOMEDS_OBSERVER + // with GUI observers this check is not needed anymore if ( aComponent->ComponentDataType() == study->getVisualComponentName().toLatin1().constData() ) continue; // skip the magic "Interface Applicative" component - +#endif if ( !objectBrowser() ) getWindow( WT_ObjectBrowser ); const bool isAutoUpdate = objectBrowser()->autoUpdate(); diff --git a/src/SalomeApp/SalomeApp_DataModel.cxx b/src/SalomeApp/SalomeApp_DataModel.cxx index f64cf4776..0de502175 100644 --- a/src/SalomeApp/SalomeApp_DataModel.cxx +++ b/src/SalomeApp/SalomeApp_DataModel.cxx @@ -85,6 +85,10 @@ SalomeApp_DataModelSync::SalomeApp_DataModelSync( _PTR( Study ) aStudy, SUIT_Dat */ bool SalomeApp_DataModelSync::isCorrect( const kerPtr& so ) const { +#ifdef WITH_SALOMEDS_OBSERVER + // with GUI observers this function is not needed anymore + return true; +#endif kerPtr refObj; QString name = so->GetName().c_str(); _PTR( GenericAttribute ) anAttr;