Salome HOME
Using LightApp_SelectionMgr
authornds <nds@opencascade.com>
Thu, 3 Nov 2005 07:59:08 +0000 (07:59 +0000)
committernds <nds@opencascade.com>
Thu, 3 Nov 2005 07:59:08 +0000 (07:59 +0000)
src/SALOME_PYQT/SalomePyQt/SalomePyQt.cxx
src/SALOME_PYQT/SalomePyQt/SalomePyQt.h
src/SALOME_SWIG/SALOMEGUI_Swig.cxx

index e01efbd3d205ff89f497ff16c90383c66486cb4c..df86577633270daa313e2e9f4eb30a263ce08404 100644 (file)
@@ -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 )
index f39dba9bfb2eebb4cdcc726f09f734697455f245..6d9feb87d7578282d7712277ef7ede65339844c5 100644 (file)
@@ -14,7 +14,7 @@
 #include <qobject.h>
 #include <qcolor.h>
 
-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* );
 };
 
index 088c576ebfc6dee4abf061bb271e34fc2a6345ac..c4c2382c4b875f68734fd31042f3cc9758297edc 100644 (file)
@@ -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<SalomeApp_Study*>( anApp->activeStudy() ); // for sure!
-      SalomeApp_SelectionMgr* aSelMgr = anApp->selectionMgr(); 
+      SalomeApp_Study*       aStudy  = dynamic_cast<SalomeApp_Study*>( 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<SalomeApp_Study*>( anApp->activeStudy() ); // for sure!
-      SalomeApp_SelectionMgr* aSelMgr = anApp->selectionMgr(); 
+      SalomeApp_Study*       aStudy  = dynamic_cast<SalomeApp_Study*>( 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<SalomeApp_Study*>( anApp->activeStudy() ); // for sure!
-       SalomeApp_SelectionMgr* aSelMgr = anApp->selectionMgr(); 
+       SalomeApp_Study*       aStudy  = dynamic_cast<SalomeApp_Study*>( 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<SalomeApp_Study*>( anApp->activeStudy() ); // for sure!
-       SalomeApp_SelectionMgr* aSelMgr = anApp->selectionMgr(); 
+       SalomeApp_Study*       aStudy  = dynamic_cast<SalomeApp_Study*>( 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<SalomeApp_Study*>( anApp->activeStudy() ); // for sure!
-       SalomeApp_SelectionMgr* aSelMgr = anApp->selectionMgr(); 
+       SalomeApp_Study*       aStudy  = dynamic_cast<SalomeApp_Study*>( anApp->activeStudy() ); // for sure!
+       LightApp_SelectionMgr* aSelMgr = anApp->selectionMgr(); 
        if ( aStudy && aSelMgr )
          aSelMgr->clearSelected();
       }