From 765ec41de79da279a808efa0756582b52b3a89c2 Mon Sep 17 00:00:00 2001 From: msv Date: Wed, 13 Jul 2005 06:35:33 +0000 Subject: [PATCH] debug IPAL9411: redefine virtual methods createEmptyStudy and activateModule in order to call updateTree of object browser. It is due to removing call of updateTree during treating the signal rootChanged of CAM_Study. --- src/SalomeApp/SalomeApp_Application.cxx | 14 ++++++++++++++ src/SalomeApp/SalomeApp_Application.h | 3 +++ 2 files changed, 17 insertions(+) diff --git a/src/SalomeApp/SalomeApp_Application.cxx b/src/SalomeApp/SalomeApp_Application.cxx index d5ff6ffff..18fde6a4a 100644 --- a/src/SalomeApp/SalomeApp_Application.cxx +++ b/src/SalomeApp/SalomeApp_Application.cxx @@ -1691,3 +1691,17 @@ void SalomeApp_Application::onDesktopActivated() if(aModule) aModule->studyActivated(); } + +void SalomeApp_Application::createEmptyStudy() +{ + CAM_Application::createEmptyStudy(); + if ( objectBrowser() ) + objectBrowser()->updateTree(); +} + +bool SalomeApp_Application::activateModule( CAM_Module* mod ) +{ + CAM_Application::activateModule( mod ); + if ( objectBrowser() ) + objectBrowser()->updateTree(); +} diff --git a/src/SalomeApp/SalomeApp_Application.h b/src/SalomeApp/SalomeApp_Application.h index 7ccc85442..94ed79b40 100644 --- a/src/SalomeApp/SalomeApp_Application.h +++ b/src/SalomeApp/SalomeApp_Application.h @@ -101,6 +101,8 @@ public: virtual void contextMenuPopup( const QString&, QPopupMenu*, QString& ); + virtual void createEmptyStudy(); + static CORBA::ORB_var orb(); static SALOMEDSClient_StudyManager* studyMgr(); static SALOME_NamingService* namingService(); @@ -143,6 +145,7 @@ protected: virtual void afterCloseDoc(); virtual void moduleAdded( CAM_Module* ); + virtual bool activateModule( CAM_Module* = 0 ); SalomeApp_Preferences* preferences( const bool ) const; -- 2.39.2