Salome HOME
Clear info panel when module is deactivated
[modules/gui.git] / src / LightApp / LightApp_Application.h
index 82668bfadc9540f868834f258348f81b37204744..c6e43cf47ee0b550a4e22fcb3acf66c3f7d70a22 100644 (file)
@@ -1,4 +1,4 @@
-// Copyright (C) 2007-2019  CEA/DEN, EDF R&D, OPEN CASCADE
+// Copyright (C) 2007-2022  CEA/DEN, EDF R&D, OPEN CASCADE
 //
 // Copyright (C) 2003-2007  OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
 // CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
@@ -40,6 +40,7 @@
 #include <QStringList>
 
 class LogWindow;
+class QtxInfoPanel;
 #ifndef DISABLE_PYCONSOLE
 class PyConsole_Console;
 class PyConsole_Interp;
@@ -75,6 +76,7 @@ class LIGHTAPP_EXPORT LightApp_Application : public CAM_Application, public SUIT
 
 public:
   typedef enum { WT_ObjectBrowser,
+                WT_InfoPanel,
 #ifndef DISABLE_PYCONSOLE
                  WT_PyConsole,
 #endif
@@ -89,6 +91,7 @@ public:
          PreferencesId, MRUId, ModulesListId,
          NewGLViewId, NewPlot2dId, NewOCCViewId, NewVTKViewId,
          NewQxSceneViewId, NewGraphicsViewId, NewPVViewId, NewPyViewerId, StyleId, FullScreenId,
+         WebSiteId, ForumId, VideosId, TutorialsId,
          UserID };
 
 protected:
@@ -110,6 +113,7 @@ public:
 
   LogWindow*                          logWindow();
   SUIT_DataBrowser*                   objectBrowser();
+  QtxInfoPanel*                       infoPanel();
 #ifndef DISABLE_PYCONSOLE
   PyConsole_Console*                  pythonConsole(const bool force = false);
 #endif
@@ -178,7 +182,10 @@ public:
   void                                emitOperationFinished( const QString&, const QString&, const QStringList& );
 
   void                                updateVisibilityState( DataObjectList& theList,
-                                                             SUIT_ViewModel* theViewModel );  
+                                                             SUIT_ViewModel* theViewModel );
+
+  void                                updatePresentations( const QString& theComponent,
+                                                           const QStringList& theViewManagerTypes );
 
   virtual bool                        checkExistingDoc( bool = true );
 
@@ -222,9 +229,12 @@ protected:
   virtual void                        setActiveStudy( SUIT_Study* );
   virtual void                        updateCommandsStatus();
 
+  virtual bool                        canOpenDoc( const QString& );
+
   virtual void                        beforeCloseDoc( SUIT_Study* );
   virtual void                        afterCloseDoc();
   virtual void                        moduleAdded( CAM_Module* );
+  virtual void                        moduleDeactivated( CAM_Module* );
   virtual bool                        activateModule( CAM_Module* = 0 );
 
   LightApp_Preferences*               preferences( const bool ) const;
@@ -264,6 +274,8 @@ protected slots:
 
   virtual void                        onDesktopMessage( const QString& );
 
+  virtual void                        onInfoPanelShown();
+
 private slots:
   void                                onSelection();
   void                                onRefresh();
@@ -307,12 +319,13 @@ protected:
   virtual bool                        openAction( const int, const QString& );
 
   void                                showPreferences( const QString& = QString() );
+  void                                showPreferences( const QStringList& );
 
 private:
   void                                emptyPreferences( const QString& );
   QList<QToolBar*>                    findToolBars( const QStringList& names = QStringList() );
-  
-  QByteArray                          processState(QByteArray& input, 
+
+  QByteArray                          processState(QByteArray& input,
                                                   const bool processWin,
                                                   const bool processTb,
                                                   const bool isRestoring,