]> SALOME platform Git repositories - modules/med.git/commitdiff
Salome HOME
CMake improvement: usage of SALOME_GUI_MODE() macro
authormpa <mpa@opencascade.com>
Thu, 11 Jun 2015 11:51:23 +0000 (14:51 +0300)
committermpa <mpa@opencascade.com>
Thu, 11 Jun 2015 11:51:23 +0000 (14:51 +0300)
CMakeLists.txt
src/MEDOP/gui/MEDOPModule.cxx
src/MEDOP/gui/XmedConsoleDriver.cxx

index a94e5e6373a6247562c7c007f66cc9475b128111..51a6514c3b316e0d892dda25b862c588f6defb1f 100644 (file)
@@ -147,7 +147,8 @@ IF(SALOME_BUILD_GUI)
     IF(EXISTS ${GUI_ROOT_DIR})
       LIST(APPEND CMAKE_MODULE_PATH "${GUI_ROOT_DIR}/adm_local/cmake_files")
       FIND_PACKAGE(SalomeGUI REQUIRED)
-      FULL_GUI(TRUE) # check whether GUI builded in full mode and with CORBA
+      SALOME_GUI_WITH_CORBA() #check whether GUI builded with CORBA
+      SALOME_GUI_MODE(SALOME_USE_SALOMEOBJECT SALOME_USE_PYCONSOLE OPTIONAL SALOME_USE_PVVIEWER)
       ADD_DEFINITIONS(${GUI_DEFINITIONS})
       INCLUDE_DIRECTORIES(${GUI_INCLUDE_DIRS})
     ELSE(EXISTS ${GUI_ROOT_DIR})
index ff3ea17c7164dd31c4dea74e8c9e13d8c3d5ff6f..88139f75251c711c0f63c9a8c83031abfeb168bd 100644 (file)
@@ -26,7 +26,9 @@
 #include CORBA_CLIENT_HEADER(SALOMEDS)
 
 #include "MEDOPFactoryClient.hxx"
+#ifndef DISABLE_PVVIEWER
 #include "PVViewer_ViewModel.h"
+#endif
 
 MEDOPModule::MEDOPModule() :
   StandardApp_Module()
@@ -106,5 +108,7 @@ void MEDOPModule::createModuleActions() {
 
 void MEDOPModule::viewManagers( QStringList& list ) const
 {
+#ifndef DISABLE_PVVIEWER
   list.append( PVViewer_Viewer::Type() );
+#endif
 }
index ea9797bb986dab6f2f8b3d64ec49a64ff9e8a227..500879c1e488b443c429d8bb9af3c60470727db3 100644 (file)
@@ -52,10 +52,12 @@ void XmedConsoleDriver::setup() {
     // A last one to clear the console screen
     //commands+="wipe";
 
+#ifndef DISABLE_PVVIEWER
     // start PVServer and show render view
     commands+="import pvsimple as pvs";
     commands+="";
     //commands+="pvs.ShowParaviewView()";
+#endif
 
     this->exec(commands);
     _importXmedDone = true;