From 9b85f317987edb9b0a03c506232e56d0c82629e5 Mon Sep 17 00:00:00 2001 From: nds Date: Thu, 3 Nov 2005 07:59:08 +0000 Subject: [PATCH] Using LightApp_SelectionMgr --- src/SALOME_PYQT/SalomePyQt/SalomePyQt.cxx | 10 +++++----- src/SALOME_PYQT/SalomePyQt/SalomePyQt.h | 4 ++-- src/SALOME_SWIG/SALOMEGUI_Swig.cxx | 24 +++++++++++------------ 3 files changed, 19 insertions(+), 19 deletions(-) diff --git a/src/SALOME_PYQT/SalomePyQt/SalomePyQt.cxx b/src/SALOME_PYQT/SalomePyQt/SalomePyQt.cxx index e01efbd3d..df8657763 100644 --- a/src/SALOME_PYQT/SalomePyQt/SalomePyQt.cxx +++ b/src/SALOME_PYQT/SalomePyQt/SalomePyQt.cxx @@ -25,7 +25,7 @@ #include "STD_MDIDesktop.h" #include "SalomeApp_Application.h" #include "SalomeApp_Study.h" -#include "SalomeApp_SelectionMgr.h" +#include "LightApp_SelectionMgr.h" #include "OB_Browser.h" #include "QtxAction.h" @@ -114,9 +114,9 @@ void SALOME_Selection::onSelMgrDestroyed() void SALOME_Selection::Clear() { class TEvent: public SALOME_Event { - SalomeApp_SelectionMgr* mySelMgr; + LightApp_SelectionMgr* mySelMgr; public: - TEvent( SalomeApp_SelectionMgr* selMgr ) + TEvent( LightApp_SelectionMgr* selMgr ) : mySelMgr( selMgr ) {} virtual void Execute() { if ( mySelMgr ) @@ -142,9 +142,9 @@ void SALOME_Selection::ClearIObjects() void SALOME_Selection::ClearFilters() { class TEvent: public SALOME_Event { - SalomeApp_SelectionMgr* mySelMgr; + LightApp_SelectionMgr* mySelMgr; public: - TEvent( SalomeApp_SelectionMgr* selMgr ) + TEvent( LightApp_SelectionMgr* selMgr ) : mySelMgr( selMgr ) {} virtual void Execute() { if ( mySelMgr ) diff --git a/src/SALOME_PYQT/SalomePyQt/SalomePyQt.h b/src/SALOME_PYQT/SalomePyQt/SalomePyQt.h index f39dba9bf..6d9feb87d 100644 --- a/src/SALOME_PYQT/SalomePyQt/SalomePyQt.h +++ b/src/SALOME_PYQT/SalomePyQt/SalomePyQt.h @@ -14,7 +14,7 @@ #include #include -class SalomeApp_SelectionMgr; +class LightApp_SelectionMgr; class SalomeApp_Application; class QMenuBar; class QPopupMenu; @@ -40,7 +40,7 @@ private slots: void onSelMgrDestroyed(); private: - SalomeApp_SelectionMgr* mySelMgr; + LightApp_SelectionMgr* mySelMgr; SALOME_Selection( QObject* ); }; diff --git a/src/SALOME_SWIG/SALOMEGUI_Swig.cxx b/src/SALOME_SWIG/SALOMEGUI_Swig.cxx index 088c576eb..c4c2382c4 100644 --- a/src/SALOME_SWIG/SALOMEGUI_Swig.cxx +++ b/src/SALOME_SWIG/SALOMEGUI_Swig.cxx @@ -36,7 +36,7 @@ #include "SalomeApp_Study.h" #include "SalomeApp_Module.h" #include "SalomeApp_DataObject.h" -#include "SalomeApp_SelectionMgr.h" +#include "LightApp_SelectionMgr.h" #include "SALOME_Prs.h" #include "SOCC_ViewModel.h" #include "SVTK_ViewModel.h" @@ -241,8 +241,8 @@ public: TSelectedCountEvent() : myResult( 0 ) {} virtual void Execute() { if ( SalomeApp_Application* anApp = getApplication() ) { - SalomeApp_Study* aStudy = dynamic_cast( anApp->activeStudy() ); // for sure! - SalomeApp_SelectionMgr* aSelMgr = anApp->selectionMgr(); + SalomeApp_Study* aStudy = dynamic_cast( anApp->activeStudy() ); // for sure! + LightApp_SelectionMgr* aSelMgr = anApp->selectionMgr(); if ( aStudy && aSelMgr ) { SALOME_ListIO anIOList; aSelMgr->selectedObjects( anIOList ); @@ -268,8 +268,8 @@ public: TGetSelectedEvent( int theIndex ) : myIndex( theIndex ) {} virtual void Execute() { if ( SalomeApp_Application* anApp = getApplication() ) { - SalomeApp_Study* aStudy = dynamic_cast( anApp->activeStudy() ); // for sure! - SalomeApp_SelectionMgr* aSelMgr = anApp->selectionMgr(); + SalomeApp_Study* aStudy = dynamic_cast( anApp->activeStudy() ); // for sure! + LightApp_SelectionMgr* aSelMgr = anApp->selectionMgr(); if ( aStudy && aSelMgr ) { SALOME_ListIO anIOList; aSelMgr->selectedObjects( anIOList ); @@ -305,8 +305,8 @@ void SALOMEGUI_Swig::AddIObject( const char* theEntry ) TEvent( const char* theEntry ) : myEntry( theEntry ) {} virtual void Execute() { if ( SalomeApp_Application* anApp = getApplication() ) { - SalomeApp_Study* aStudy = dynamic_cast( anApp->activeStudy() ); // for sure! - SalomeApp_SelectionMgr* aSelMgr = anApp->selectionMgr(); + SalomeApp_Study* aStudy = dynamic_cast( anApp->activeStudy() ); // for sure! + LightApp_SelectionMgr* aSelMgr = anApp->selectionMgr(); if ( aStudy && aSelMgr ) { SALOME_ListIO anIOList; anIOList.Append( new SALOME_InteractiveObject( myEntry, "", "" ) ); @@ -329,11 +329,11 @@ void SALOMEGUI_Swig::RemoveIObject( const char* theEntry ) TEvent( const char* theEntry ) : myEntry( theEntry ) {} virtual void Execute() { if ( SalomeApp_Application* anApp = getApplication() ) { - SalomeApp_Study* aStudy = dynamic_cast( anApp->activeStudy() ); // for sure! - SalomeApp_SelectionMgr* aSelMgr = anApp->selectionMgr(); + SalomeApp_Study* aStudy = dynamic_cast( anApp->activeStudy() ); // for sure! + LightApp_SelectionMgr* aSelMgr = anApp->selectionMgr(); if ( aStudy && aSelMgr ) { SALOME_ListIO anIOList; - // VSR: temporary solution, until SalomeApp_SelectionMgr::unsetSelectedObjects() method appears + // VSR: temporary solution, until LightApp_SelectionMgr::unsetSelectedObjects() method appears // Lately this should be replaced by the following: // anIOList.Append( new SALOME_InteractiveObject( myEntry, "", "" ) ); // aSelMgr->unsetSelectedObjects( anIOList ); @@ -364,8 +364,8 @@ void SALOMEGUI_Swig::ClearIObjects() TEvent() {} virtual void Execute() { if ( SalomeApp_Application* anApp = getApplication() ) { - SalomeApp_Study* aStudy = dynamic_cast( anApp->activeStudy() ); // for sure! - SalomeApp_SelectionMgr* aSelMgr = anApp->selectionMgr(); + SalomeApp_Study* aStudy = dynamic_cast( anApp->activeStudy() ); // for sure! + LightApp_SelectionMgr* aSelMgr = anApp->selectionMgr(); if ( aStudy && aSelMgr ) aSelMgr->clearSelected(); } -- 2.39.2