]> SALOME platform Git repositories - modules/paravis.git/commitdiff
Salome HOME
Moving resources to GUI.
authorabn <adrien.bruneton@cea.fr>
Thu, 16 Oct 2014 11:11:37 +0000 (13:11 +0200)
committerabn <adrien.bruneton@cea.fr>
Thu, 16 Oct 2014 11:11:37 +0000 (13:11 +0200)
13 files changed:
resources/CMakeLists.txt
resources/ParaViewFilters.xml [deleted file]
resources/ParaViewReaders.xml [deleted file]
resources/ParaViewSources.xml [deleted file]
resources/ParaViewWriters.xml [deleted file]
src/ENGINE/no_wrap/PARAVIS.py.in
src/PVGUI/CMakeLists.txt
src/PVGUI/PVGUI_DataModel.cxx [new file with mode: 0644]
src/PVGUI/PVGUI_DataModel.h [new file with mode: 0644]
src/PVGUI/PVGUI_Module.cxx
src/PVGUI/PVGUI_Module.h
src/PVGUI/PVGUI_Module_actions.cxx
src/PVGUI/PVGUI_Module_widgets.cxx

index 9dcfd1414645c0fe4055f143b2c135276c31ba8c..4cb6e1c872aa417f6b91d8f0d5c7160d6f6be796 100644 (file)
 SET(dist_salomeres_DATA
   pqAppIcon22.png
   pqAppIcon16.png
-  ParaViewFilters.xml
-  ParaViewReaders.xml
-  ParaViewSources.xml
-  ParaViewWriters.xml
   )
 
 SET(input ${CMAKE_CURRENT_SOURCE_DIR}/PARAVISCatalog.xml.in)
diff --git a/resources/ParaViewFilters.xml b/resources/ParaViewFilters.xml
deleted file mode 100755 (executable)
index 22eb6da..0000000
+++ /dev/null
@@ -1,215 +0,0 @@
-<ParaViewFilters>
-  <Category name="Cosmology" menu_label="Cosmology">
-    <Proxy group="filters" name="HaloFinder" />
-  </Category>
-
-  <Category name="Common" menu_label="&amp;Common" preserve_order="1"
-    show_in_toolbar="1">
-    <Proxy group="filters" name="Calculator" icon=":/pqWidgets/Icons/pqCalculator24.png"/>
-    <Proxy group="filters" name="Contour" icon=":/pqWidgets/Icons/pqIsosurface24.png"/>
-    <Proxy group="filters" name="Clip" icon=":/pqWidgets/Icons/pqClip24.png"/>
-    <Proxy group="filters" name="Cut" icon=":/pqWidgets/Icons/pqSlice24.png"/>
-    <Proxy group="filters" name="Threshold" icon=":/pqWidgets/Icons/pqThreshold24.png"/>
-    <Proxy group="filters" name="ExtractGrid" icon=":/pqWidgets/Icons/pqExtractGrid24.png"/>
-    <Proxy group="filters" name="Glyph" icon=":/pqWidgets/Icons/pqGlyph24.png"/>
-    <Proxy group="filters" name="StreamTracer" icon=":/pqWidgets/Icons/pqStreamTracer24.png"/>
-    <Proxy group="filters" name="WarpVector" icon=":/pqWidgets/Icons/pqWarp24.png"/>
-    <Proxy group="filters" name="GroupDataSets" icon=":/pqWidgets/Icons/pqGroup24.png"/>
-    <Proxy group="filters" name="ExtractHierarchicalLevel" icon=":/pqWidgets/Icons/pqGroupExtract24.png"/>
-  </Category>
-
-  <Category name="DataAnalysis" menu_label="&amp;Data Analysis" show_in_toolbar="1" hide_for_tests="1">
-    <Proxy group="filters" name="Calculator"
-            icon=":/pqWidgets/Icons/pqCalculator24.png" omit_from_toolbar="1"/>
-    <Proxy group="filters" name="ExtractSelection"
-            icon=":/pqWidgets/Icons/pqExtractSelection24.png" />
-    <Proxy group="filters" name="ExtractSelectionOverTime"
-            icon=":/pqWidgets/Icons/pqPlotSelectionOverTime24.png" />
-    <Proxy group="filters" name="ExtractHistogram"
-            icon=":/pqWidgets/Icons/pqHistogram24.png" omit_from_toolbar="1"/>
-    <Proxy group="filters" name="IntegrateAttributes" omit_from_toolbar="1"/>
-    <Proxy group="filters" name="ExtractFieldDataOverTime"
-            icon=":/pqWidgets/Icons/pqPlotGlobalOverTime24.png" />
-    <Proxy group="filters" name="ProbeLine"
-            icon=":/pqWidgets/Icons/pqPlotOverLine24.png" />
-    <Proxy group="filters" name="ProbePoint"
-            icon=":/pqWidgets/Icons/pqProbeLocation24.png" />
-    <Proxy group="filters" name="PlotAttributes" omit_from_toolbar="1"/>
-    <Proxy group="filters" name="PlotOnSortedLines" omit_from_toolbar="1"/>
-    <Proxy group="filters" name="PlotOnIntersectionCurves" omit_from_toolbar="1"/>
-    <Proxy group="filters" name="ProgrammableFilter"
-            icon=":/pqWidgets/Icons/pqProgrammableFilter24.png" omit_from_toolbar="1"/>
-  </Category>
-
-  <Category name="Statistics" menu_label="&amp;Statistics">
-    <Proxy group="filters" name="ContingencyStatistics"/>
-    <Proxy group="filters" name="DescriptiveStatistics"/>
-    <Proxy group="filters" name="KMeans"/>
-    <Proxy group="filters" name="MulticorrelativeStatistics"/>
-    <Proxy group="filters" name="PCAStatistics"/>
-  </Category>
-
-  <Category name="Temporal" menu_label="&amp;Temporal">
-    <Proxy group="filters" name="ParticleTracer" />
-    <Proxy group="filters" name="ParticlePath" />
-    <Proxy group="filters" name="StreakLine" />
-    <Proxy group="filters" name="TemporalCache" />
-    <Proxy group="filters" name="TemporalInterpolator" />
-    <Proxy group="filters" name="TemporalSnapToTimeStep" />
-    <Proxy group="filters" name="TemporalShiftScale" />
-    <Proxy group="filters" name="TemporalStatistics" />
-    <Proxy group="filters" name="TimeToTextConvertor" />
-  </Category>
-
-  <Category name="Material Analysis" menu_label="&amp;Material Analysis">
-    <Proxy group="filters" name="MaterialInterfaceFilter" />
-    <Proxy group="filters" name="IntersectFragments" />
-  </Category>
-
-  <Category name="CTH" menu_label="&amp;CTH">
-    <Proxy group="filters" name="CTHFragmentConnect"/>
-    <Proxy group="filters" name="CTHFragmentIntersect"/>
-    <Proxy group="filters" name="CTHPart" />
-    <Proxy group="filters" name="NonOverlappingLevelIdScalars" />
-    <Proxy group="filters" name="MaterialInterfaceFilter" />
-    <Proxy group="filters" name="AMRDualClip" />
-    <Proxy group="filters" name="AMRDualContour" />
-    <Proxy group="filters" name="ExtractHierarchicalLevel" />
-    <Proxy group="filters" name="ExtractHierarchicalDataSets" />
-  </Category>
-
-  <Category name="AMR" menu_label="&amp;AMR">
-    <Proxy group="filters" name="AMRDualMeshExtractor" />
-    <Proxy group="filters" name="AMRResampleFilter" />
-    <Proxy group="filters" name="AMRSlice" />
-    <Proxy group="filters" name="AMRToMultiBlock" />
-    <Proxy group="filters" name="AMRCutPlane" />
-    <Proxy group="filters" name="OverlappingLevelIdScalars" />
-    <Proxy group="filters" name="ExtractHierarchicalLevel" />
-    <Proxy group="filters" name="ExtractHierarchicalDataSets" />
-  </Category>
-
-  <Proxy group="filters" name="ImageDataToAMR" />
-  <Proxy group="filters" name="UniformGridPartitioner" />
-  <Proxy group="filters" name="AnnotateGlobalData" />
-  <Proxy group="filters" name="Append" />
-  <Proxy group="filters" name="AppendAttributes" />
-  <Proxy group="filters" name="AppendPolyData" />
-  <Proxy group="filters" name="ArbitrarySourceGlyph" />
-  <Proxy group="filters" name="ArbitrarySourceStreamTracer" />
-  <Proxy group="filters" name="BlockIdScalars" />
-  <Proxy group="filters" name="BrownianPoints" />
-  <Proxy group="filters" name="Calculator" />
-  <Proxy group="filters" name="CellCenters" />
-  <Proxy group="filters" name="CellDataToPointData" />
-  <Proxy group="filters" name="CellDerivatives"/>
-  <Proxy group="filters" name="CleanPolyData" />
-  <Proxy group="filters" name="CleanUnstructuredGrid" />
-  <Proxy group="filters" name="CleanUnstructuredGridCells" />
-  <Proxy group="filters" name="Clip" />
-  <Proxy group="filters" name="ClipClosedSurface" />
-  <Proxy group="filters" name="Contour" />
-  <Proxy group="filters" name="Curvatures" />
-  <Proxy group="filters" name="Cut" />
-  <Proxy group="filters" name="CutEverything" />
-  <Proxy group="filters" name="D3" />
-  <Proxy group="filters" name="DataSetSurfaceFilter" />
-  <Proxy group="filters" name="DataSetTriangleFilter" />
-  <Proxy group="filters" name="DecimatePro" />
-  <Proxy group="filters" name="Delaunay2D" />
-  <Proxy group="filters" name="Delaunay3D" />
-  <Proxy group="filters" name="ElevationFilter" />
-  <Proxy group="filters" name="ExtractBlock" />
-  <Proxy group="filters" name="ExtractEdges" />
-  <Proxy group="filters" name="ExtractGeometry" />
-  <Proxy group="filters" name="ExtractGrid" />
-  <Proxy group="filters" name="ExtractHistogram" />
-  <Proxy group="filters" name="ExtractSelection" />
-  <Proxy group="filters" name="ExtractSelectionOverTime" />
-  <Proxy group="filters" name="FeatureEdges" />
-  <Proxy group="filters" name="FFTSelectionOverTime" />
-  <Proxy group="filters" name="GaussianSplatter"/>
-  <Proxy group="filters" name="GenerateIdScalars"/>
-  <Proxy group="filters" name="Glyph" />
-  <Proxy group="filters" name="Gradient" />
-  <Proxy group="filters" name="GridConnectivity" />
-  <Proxy group="filters" name="GroupDataSets" />
-  <Proxy group="filters" name="ImageDataToAMR" />
-  <Proxy group="filters" name="ImageDataToPointSet" />
-  <Proxy group="filters" name="IntegrateAttributes" />
-  <Proxy group="filters" name="IntegrateFlowThroughSurface" />
-  <!--  <Proxy group="filters" name="LevelIdScalars" /> -->
-  <Proxy group="filters" name="LinearExtrusionFilter" />
-  <Proxy group="filters" name="LoopSubdivisionFilter" />
-  <Proxy group="filters" name="MaskPoints" />
-  <Proxy group="filters" name="Median" />
-  <Proxy group="filters" name="MergeBlocks" />
-  <Proxy group="filters" name="MeshQuality" />
-  <Proxy group="filters" name="OctreeDepthLimit" />
-  <Proxy group="filters" name="OctreeDepthScalars" />
-  <Proxy group="filters" name="OutlineCornerFilter" />
-  <Proxy group="filters" name="OutlineFilter" />
-  <Proxy group="filters" name="ParticlePathLines" />
-  <Proxy group="filters" name="ParticleTracer" />
-  <Proxy group="filters" name="PassArrays" />
-  <Proxy group="filters" name="PlotAttributes" />
-  <Proxy group="filters" name="PlotOnIntersectionCurves" />
-  <Proxy group="filters" name="PlotOnSortedLines" />
-  <Proxy group="filters" name="PointDataToCellData" />
-  <Proxy group="filters" name="PolyDataNormals" />
-  <Proxy group="filters" name="Probe" />
-  <Proxy group="filters" name="ProbeLine" />
-  <Proxy group="filters" name="ProbePoint" />
-  <Proxy group="filters" name="ProcessIdScalars" />
-  <Proxy group="filters" name="ProgrammableFilter" />
-  <Proxy group="filters" name="PVConnectivityFilter" />
-  <Proxy group="filters" name="PythonCalculator" />
-  <Proxy group="filters" name="PythonAnnotation" />
-  <Proxy group="filters" name="PythonExtractSelection" />
-  <Proxy group="filters" name="QuadraturePointInterpolator" />
-  <Proxy group="filters" name="QuadraturePointsGenerator" />
-  <Proxy group="filters" name="QuadraturePointStatistics" />
-  <Proxy group="filters" name="QuadratureSchemeDictionaryGenerator" />
-  <Proxy group="filters" name="QuadricClustering" />
-  <Proxy group="filters" name="RectilinearGridConnectivity" />
-  <Proxy group="filters" name="RectilinearGridToPointSet" />
-  <Proxy group="filters" name="ReflectionFilter" />
-  <Proxy group="filters" name="RibbonFilter" />
-  <Proxy group="filters" name="RotationalExtrusionFilter" />
-  <Proxy group="filters" name="ScatterPlot"/>
-  <Proxy group="filters" name="ShrinkFilter" />
-  <Proxy group="filters" name="SmoothPolyDataFilter" />
-  <Proxy group="filters" name="StreamTracer" />
-  <Proxy group="filters" name="Stripper" />
-  <Proxy group="filters" name="StructuredGridOutlineFilter" />
-  <Proxy group="filters" name="Subdivide" />
-  <Proxy group="filters" name="SurfaceVectors" />
-  <Proxy group="filters" name="TemporalCache" />
-  <Proxy group="filters" name="TemporalInterpolator" />
-  <Proxy group="filters" name="TemporalSnapToTimeStep" />
-  <Proxy group="filters" name="TemporalShiftScale" />
-  <Proxy group="filters" name="TemporalStatistics" />
-  <Proxy group="filters" name="TessellatorFilter" />
-  <Proxy group="filters" name="TextureMapToCylinder" />
-  <Proxy group="filters" name="TextureMapToPlane" />
-  <Proxy group="filters" name="TextureMapToSphere" />
-  <Proxy group="filters" name="Threshold" />
-  <Proxy group="filters" name="TimeToTextConvertor" />
-  <Proxy group="filters" name="TransformFilter" />
-  <Proxy group="filters" name="TriangleFilter" />
-  <Proxy group="filters" name="TubeFilter" />
-  <Proxy group="filters" name="UnstructuredGradient" />
-  <Proxy group="filters" name="WarpScalar" />
-  <Proxy group="filters" name="WarpVector" />
-  <Proxy group="filters" name="YoungsMaterialInterface"/>
-  <Proxy group="filters" name="NormalGlyphs" />
-  <Proxy group="filters" name="TableToPolyData" />
-  <Proxy group="filters" name="TableToStructuredGrid" />
-  <Proxy group="filters" name="IsoVolume" />
-
-  <Proxy group="filters" name="GenericClip" />
-  <Proxy group="filters" name="GenericContour" />
-  <Proxy group="filters" name="GenericCut" />
-  <Proxy group="filters" name="GenericStreamTracer" />
-  <Proxy group="filters" name="GenericGeometryFilter" />
-</ParaViewFilters>
diff --git a/resources/ParaViewReaders.xml b/resources/ParaViewReaders.xml
deleted file mode 100755 (executable)
index dd88e53..0000000
+++ /dev/null
@@ -1,78 +0,0 @@
-<ParaViewReaders>
-  <!--
-    NOTE: Readers are tried in reverse order that they are present in this
-    list i.e. if two readers can read the same extension, then the reader
-    apperaring later will be tried first when reading the file.
-  -->
-  <ProxyManager type="reader" />
-  <Proxy group="sources" name="LSDynaReader" />
-  <Proxy group="sources" name="PVDReader" />
-  <Proxy group="sources" name="XMLHierarchicalBoxDataReader" />
-  <Proxy group="sources" name="XMLPolyDataReader"/>
-  <Proxy group="sources" name="XMLUnstructuredGridReader" />
-  <Proxy group="sources" name="XMLImageDataReader" />
-  <Proxy group="sources" name="XMLStructuredGridReader" />
-  <Proxy group="sources" name="XMLRectilinearGridReader" />
-  <Proxy group="sources" name="XMLPPolyDataReader" />
-  <Proxy group="sources" name="XMLPUnstructuredGridReader" />
-  <Proxy group="sources" name="XMLPImageDataReader" />
-  <Proxy group="sources" name="XMLPStructuredGridReader" />
-  <Proxy group="sources" name="XMLPRectilinearGridReader" />
-  <Proxy group="sources" name="XMLMultiBlockDataReader" />
-  <Proxy group="sources" name="XMLUniformGridAMRReader" />
-  <Proxy group="sources" name="LegacyVTKFileReader" />
-  <Proxy group="sources" name="pvtkfile" />
-  <Proxy group="sources" name="ensight" />
-  <Proxy group="sources" name="ensightMS" />
-  <Proxy group="sources" name="TecplotReader" />
-  <Proxy group="sources" name="netCDFReader" />
-  <Proxy group="sources" name="byureader" />
-  <Proxy group="sources" name="objreader" />
-  <Proxy group="sources" name="ProStarReader" />
-  <Proxy group="sources" name="XdmfReader" />
-  <Proxy group="sources" name="pdbreader" />
-  <Proxy group="sources" name="xyzreader" />
-  <Proxy group="sources" name="P3DReader" />
-  <Proxy group="sources" name="spcthreader" />
-  <Proxy group="sources" name="SPCTHRestartReader" />
-  <Proxy group="sources" name="spcthhistoryreader" />
-  <Proxy group="sources" name="DEMReader" />
-  <Proxy group="sources" name="vrmlreader" />
-  <Proxy group="sources" name="plyreader" />
-  <Proxy group="sources" name="stlreader" />
-  <Proxy group="sources" name="gaussiancubereader" />
-  <Proxy group="sources" name="ImageReader" />
-  <Proxy group="sources" name="popreader"/>
-  <Proxy group="sources" name="AVSucdSeriesReader" />
-  <Proxy group="sources" name="MetaImageReader" />
-  <Proxy group="sources" name="NrrdReader" />
-  <Proxy group="sources" name="FacetReader" />
-  <Proxy group="sources" name="PNGSeriesReader" />
-  <Proxy group="sources" name="JPEGSeriesReader" />
-  <Proxy group="sources" name="TIFFSeriesReader" />
-  <Proxy group="sources" name="PhastaReader" />
-  <Proxy group="sources" name="EnzoReader" />
-  <Proxy group="sources" name="FlashReader" />
-  <Proxy group="sources" name="SESAMEReader" />
-  <Proxy group="sources" name="CSVReader" />
-  <Proxy group="sources" name="MFIXReader" />
-  <Proxy group="sources" name="FLUENTReader" />
-  <Proxy group="sources" name="OpenFOAMReader" />
-  <Proxy group="sources" name="CosmoReader" />
-  <Proxy group="sources" name="SiloReader"/>
-  <Proxy group="sources" name="ExodusIIReader" />
-  <Proxy group="sources" name="ExodusRestartReader" />
-  <Proxy group="sources" name="SLACReader" />
-  <Proxy group="sources" name="SLACParticleReader" />
-  <Proxy group="sources" name="ParticleReader" />
-  <Proxy group="sources" name="VPICReader" />
-  <Proxy group="sources" name="WindBladeReader" />
-  <Proxy group="sources" name="NetCDFCAMReader" />
-  <Proxy group="sources" name="NetCDFPOPReader" />
-  <Proxy group="sources" name="UnstructuredPOPReader" />
-  <Proxy group="sources" name="PNetCDFPOPReader" />
-  <Proxy group="sources" name="MPASReader" />
-  <Proxy group="sources" name="EnzoParticlesReader" />
-  <Proxy group="sources" name="FlashParticlesReader" />
-  <Proxy group="sources" name="CMLMoleculeReader"/>
-</ParaViewReaders>
diff --git a/resources/ParaViewSources.xml b/resources/ParaViewSources.xml
deleted file mode 100755 (executable)
index b8b3cf8..0000000
+++ /dev/null
@@ -1,29 +0,0 @@
-<ParaViewSources>
-  <Proxy group="sources" name="GlyphSource2D" />
-  <Proxy group="sources" name="VectorText" />
-  <Proxy group="sources" name="TimeToTextConvertorSource" />
-  <Proxy group="sources" name="ArrowSource" />
-  <Proxy group="sources" name="Axes" />
-  <Proxy group="sources" name="CubeSource" />
-  <Proxy group="sources" name="ConeSource" />
-  <Proxy group="sources" name="CylinderSource" />
-  <Proxy group="sources" name="DataObjectGenerator" />
-  <Proxy group="sources" name="DiskSource" />
-  <Proxy group="sources" name="HierarchicalFractal" />
-  <Proxy group="sources" name="HyperTreeGridSource" />
-  <Proxy group="sources" name="LineSource" />
-  <Proxy group="sources" name="ImageMandelbrotSource" />
-  <Proxy group="sources" name="OctreeFractal" />
-  <Proxy group="sources" name="OutlineSource" />
-  <Proxy group="sources" name="PlaneSource" />
-  <Proxy group="sources" name="PointSource" />
-  <Proxy group="sources" name="ProgrammableSource" />
-  <Proxy group="sources" name="SphereSource" />
-  <Proxy group="sources" name="SplineSource" />
-  <Proxy group="sources" name="SuperquadricSource" />
-  <Proxy group="sources" name="TextSource" />
-  <Proxy group="sources" name="TimeSource" />
-  <Proxy group="sources" name="Ruler" />
-  <Proxy group="sources" name="RTAnalyticSource" />
-  <Proxy group="sources" name="AMRGaussianPulseSource" />
-</ParaViewSources>
diff --git a/resources/ParaViewWriters.xml b/resources/ParaViewWriters.xml
deleted file mode 100755 (executable)
index db7fd3e..0000000
+++ /dev/null
@@ -1,28 +0,0 @@
-<ParaViewWriters>
-  <ProxyManager type="writer" />
-  <Proxy group="writers" name="XMLPVDWriter" />
-  <Proxy group="writers" name="XMLHyperOctreeWriter" />
-  <Proxy group="writers" name="XMLPolyDataWriter" />
-  <Proxy group="writers" name="XMLUnstructuredGridWriter" />
-  <Proxy group="writers" name="XMLStructuredGridWriter" />
-  <Proxy group="writers" name="XMLRectilinearGridWriter" />
-  <Proxy group="writers" name="XMLImageDataWriter" />
-  <Proxy group="writers" name="XMLPPolyDataWriter" />
-  <Proxy group="writers" name="XMLPUnstructuredGridWriter" />
-  <Proxy group="writers" name="XMLPStructuredGridWriter" />
-  <Proxy group="writers" name="XMLPRectilinearGridWriter"/>
-  <Proxy group="writers" name="XMLPImageDataWriter" />
-  <Proxy group="writers" name="XMLMultiBlockDataWriter" />
-  <Proxy group="writers" name="XMLUniformGridAMRWriter" />
-  <Proxy group="writers" name="DataSetWriter" />
-  <Proxy group="writers" name="PDataSetWriter" />
-  <Proxy group="writers" name="PPLYWriter" />
-  <Proxy group="writers" name="PSTLWriter" />
-  <Proxy group="writers" name="MetaImageWriter" />
-  <Proxy group="writers" name="PNGWriter" />
-  <Proxy group="writers" name="XdmfWriter"/>
-  <Proxy group="writers" name="ExodusIIWriter" />
-  <Proxy group="writers" name="EnSightWriter" />
-  <Proxy group="writers" name="CSVWriter" />
-  <Proxy group="writers" name="DataSetCSVWriter" />
-</ParaViewWriters>
index 1dbc89ff807fb15b719bdc0bafd36e35f6d5eb03..5a7692c71aa3e65ca66b03c03fc60d3ca77a910d 100644 (file)
@@ -35,7 +35,8 @@ import os
 #from SALOME_utilities import MESSAGE
 
 def MESSAGE(m):
-    os.system("echo \"%s\" >> /tmp/paravis_log.txt" % m)
+    pass
+    #os.system("echo \"%s\" >> /tmp/paravis_log.txt" % m)
 
 class PARAVIS_Impl:
     """ The core implementation (non CORBA, or Study related).
index e8a95ccb85339a9952e135e031c72ac6c08f413f..4f387fee480364b20cd48815f13a0afb811313ad 100644 (file)
@@ -71,9 +71,7 @@ QT4_WRAP_UI(_ui_FORMS_HEADERS ${_ui_files})
 # header files / to be processed by moc
 SET(_moc_HEADERS
   PVGUI_Module.h
-#  PVGUI_ViewManager.h
-#  PVGUI_ViewModel.h
-#  PVGUI_ViewWindow.h
+  PVGUI_DataModel.h
   PVGUI_ParaViewSettingsPane.h
 )
 
@@ -145,6 +143,7 @@ SET(_other_SOURCES
   PVGUI_Module_widgets.cxx
   PVGUI_Tools.cxx
   PVGUI_ParaViewSettingsPane.cxx
+  PVGUI_DataModel.cxx
   )
 
 IF(NOT SALOME_PARAVIS_MINIMAL_CORBA)
diff --git a/src/PVGUI/PVGUI_DataModel.cxx b/src/PVGUI/PVGUI_DataModel.cxx
new file mode 100644 (file)
index 0000000..22041e3
--- /dev/null
@@ -0,0 +1,70 @@
+// Copyright (C) 2010-2014  CEA/DEN, EDF R&D
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License, or (at your option) any later version.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+//
+// Author : Adrien Bruneton (CEA)
+//
+
+#include "PVGUI_DataModel.h"
+#include "PVGUI_Module.h"
+
+#include <iostream>
+#include <QFile>
+#include <QTextStream>
+
+PVGUI_DataModel::PVGUI_DataModel( PVGUI_Module* theModule ):
+  LightApp_DataModel(theModule)
+{}
+
+PVGUI_DataModel::~PVGUI_DataModel()
+{}
+
+bool PVGUI_DataModel::dumpPython( const QString& path, CAM_Study* std,
+            bool multiFile, QStringList& listOfFiles)
+{
+  QString tmpFile("/tmp/kikou.py");
+  listOfFiles.push_back(tmpFile);
+  QFile file(tmpFile);
+  if (!file.open(QIODevice::WriteOnly | QIODevice::Text))
+    return false;
+
+  //MESSAGE("[PARAVIS] dumpPython()")
+  PVGUI_Module * mod = (PVGUI_Module *) getModule();
+  QString trace(mod->getTraceString());
+
+  if (multiFile)
+    {
+      QStringList abuffer;
+      abuffer.push_back(QString("def RebuildData( theStudy ):"));
+      QStringList lst(trace.split("\n"));
+      foreach(QString elem, lst)
+        {
+          QString s = "  " + elem;
+          abuffer.push_back(s);
+        }
+      abuffer.push_back(QString("  pass"));
+      trace = abuffer.join("\n");
+    }
+  QTextStream out(&file);
+  out << trace.toStdString().c_str() << "\n";
+  out.flush();
+  file.close();
+
+  std::cout << "@@@@@ wrote :\n" <<trace.toStdString().c_str()<< "\n";
+  return true;
+}
+
diff --git a/src/PVGUI/PVGUI_DataModel.h b/src/PVGUI/PVGUI_DataModel.h
new file mode 100644 (file)
index 0000000..426b98e
--- /dev/null
@@ -0,0 +1,46 @@
+// Copyright (C) 2010-2014  CEA/DEN, EDF R&D
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License, or (at your option) any later version.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+//
+// Author : Adrien Bruneton (CEA)
+//
+
+#ifndef PVGUIDATAMODEL_H_
+#define PVGUIDATAMODEL_H_
+
+#include <LightApp_DataModel.h>
+
+#include <QObject>
+#include <QString>
+#include <QStringList>
+
+class PVGUI_Module;
+class CAM_Study;
+
+class PVGUI_DataModel: public LightApp_DataModel
+{
+  Q_OBJECT
+
+public:
+  PVGUI_DataModel( PVGUI_Module* theModule );
+  virtual ~PVGUI_DataModel();
+
+  virtual bool dumpPython( const QString&,  CAM_Study*, bool, QStringList& );
+
+};
+
+#endif /* PVGUIDATAMODEL_H_ */
index 2f055f112ded2c637176552c970d7d387ece71c0..b96cae25e4700d3200d09ee16b06b98f40fa2b6b 100644 (file)
@@ -20,6 +20,8 @@
 //
 // File   : PVGUI_Module.cxx
 
+#define PARAVIS_MODULE_NAME "PARAVIS"
+
 #include <Standard_math.hxx>  // E.A. must be included before Python.h to fix compilation on windows
 #ifdef HAVE_FINITE
 #undef HAVE_FINITE            // VSR: avoid compilation warning on Linux : "HAVE_FINITE" redefined
 #include "PVGUI_ParaViewSettingsPane.h"
 #include "PVViewer_GUIElements.h"
 #include "PVViewer_EngineWrapper.h"
+#include "PVGUI_DataModel.h"
 
 // SALOME Includes
+#include <utilities.h>
 #include <SUIT_DataBrowser.h>
 #include <SUIT_Desktop.h>
 #include <SUIT_MessageBox.h>
@@ -56,7 +60,8 @@
 
 #include <LightApp_SelectionMgr.h>
 #include <LightApp_NameDlg.h>
-#include <SalomeApp_Application.h>
+#include <LightApp_Application.h>
+#include <SalomeApp_Application.h>  // should ultimately be a LightApp only
 #include <SalomeApp_Study.h>
 #include <SALOME_ListIO.hxx>
 #include <SALOMEDS_Tool.hxx>
 // TO REMOVE:
 #include <PyInterp_Interp.h>
 
+#include <PVViewer_EngineWrapper.h>
+
 
 //----------------------------------------------------------------------------
 PVGUI_Module* ParavisModule = 0;
@@ -203,45 +210,45 @@ PARAVIS_ORB::PARAVIS_Gen_var PVGUI_Module::MyEngine;
          SALOME module wrapping ParaView GUI.
 */
 
-_PTR(SComponent)
-ClientFindOrCreateParavisComponent(_PTR(Study) theStudyDocument)
-{
-  _PTR(SComponent) aSComponent = theStudyDocument->FindComponent("PARAVIS");
-  if (!aSComponent) {
-    _PTR(StudyBuilder) aStudyBuilder = theStudyDocument->NewBuilder();
-    aStudyBuilder->NewCommand();
-    int aLocked = theStudyDocument->GetProperties()->IsLocked();
-    if (aLocked) theStudyDocument->GetProperties()->SetLocked(false);
-    aSComponent = aStudyBuilder->NewComponent("PARAVIS");
-    _PTR(GenericAttribute) anAttr =
-      aStudyBuilder->FindOrCreateAttribute(aSComponent, "AttributeName");
-    _PTR(AttributeName) aName (anAttr);
-
-    ORB_INIT& init = *SINGLETON_<ORB_INIT>::Instance();
-    CORBA::ORB_var anORB = init( qApp->argc(), qApp->argv() );
-
-    SALOME_NamingService *NamingService = new SALOME_NamingService( anORB );
-    CORBA::Object_var objVarN = NamingService->Resolve("/Kernel/ModulCatalog");
-    SALOME_ModuleCatalog::ModuleCatalog_var Catalogue =
-      SALOME_ModuleCatalog::ModuleCatalog::_narrow(objVarN);
-    SALOME_ModuleCatalog::Acomponent_var Comp = Catalogue->GetComponent( "PARAVIS" );
-    if (!Comp->_is_nil()) {
-      aName->SetValue(Comp->componentusername());
-    }
-
-    anAttr = aStudyBuilder->FindOrCreateAttribute(aSComponent, "AttributePixMap");
-    _PTR(AttributePixMap) aPixmap (anAttr);
-    aPixmap->SetPixMap( "pqAppIcon16.png" );
-
-    // Create Attribute parameters for future using
-    anAttr = aStudyBuilder->FindOrCreateAttribute(aSComponent, "AttributeParameter");
-
-    aStudyBuilder->DefineComponentInstance(aSComponent, PVGUI_Module::GetCPPEngine()->GetIOR());
-    if (aLocked) theStudyDocument->GetProperties()->SetLocked(true);
-    aStudyBuilder->CommitCommand();
-  }
-  return aSComponent;
-}
+//_PTR(SComponent)
+//ClientFindOrCreateParavisComponent(_PTR(Study) theStudyDocument)
+//{
+//  _PTR(SComponent) aSComponent = theStudyDocument->FindComponent("PARAVIS");
+//  if (!aSComponent) {
+//    _PTR(StudyBuilder) aStudyBuilder = theStudyDocument->NewBuilder();
+//    aStudyBuilder->NewCommand();
+//    int aLocked = theStudyDocument->GetProperties()->IsLocked();
+//    if (aLocked) theStudyDocument->GetProperties()->SetLocked(false);
+//    aSComponent = aStudyBuilder->NewComponent("PARAVIS");
+//    _PTR(GenericAttribute) anAttr =
+//      aStudyBuilder->FindOrCreateAttribute(aSComponent, "AttributeName");
+//    _PTR(AttributeName) aName (anAttr);
+//
+//    ORB_INIT& init = *SINGLETON_<ORB_INIT>::Instance();
+//    CORBA::ORB_var anORB = init( qApp->argc(), qApp->argv() );
+//
+//    SALOME_NamingService *NamingService = new SALOME_NamingService( anORB );
+//    CORBA::Object_var objVarN = NamingService->Resolve("/Kernel/ModulCatalog");
+//    SALOME_ModuleCatalog::ModuleCatalog_var Catalogue =
+//      SALOME_ModuleCatalog::ModuleCatalog::_narrow(objVarN);
+//    SALOME_ModuleCatalog::Acomponent_var Comp = Catalogue->GetComponent( "PARAVIS" );
+//    if (!Comp->_is_nil()) {
+//      aName->SetValue(Comp->componentusername());
+//    }
+//
+//    anAttr = aStudyBuilder->FindOrCreateAttribute(aSComponent, "AttributePixMap");
+//    _PTR(AttributePixMap) aPixmap (anAttr);
+//    aPixmap->SetPixMap( "pqAppIcon16.png" );
+//
+//    // Create Attribute parameters for future using
+//    anAttr = aStudyBuilder->FindOrCreateAttribute(aSComponent, "AttributeParameter");
+//
+//    aStudyBuilder->DefineComponentInstance(aSComponent, PVGUI_Module::GetCPPEngine()->GetIOR());
+//    if (aLocked) theStudyDocument->GetProperties()->SetLocked(true);
+//    aStudyBuilder->CommitCommand();
+//  }
+//  return aSComponent;
+//}
 
 /*!
   Clean up function; used to stop ParaView progress events when
@@ -259,7 +266,7 @@ void paravisCleanUp()
   \brief Constructor. Sets the default name for the module.
 */
 PVGUI_Module::PVGUI_Module()
-  : SalomeApp_Module( "PARAVIS" ),
+    : SalomeApp_Module( PARAVIS_MODULE_NAME ),
     mySelectionControlsTb( -1 ),
     mySourcesMenuId( -1 ),
     myFiltersMenuId( -1 ),
@@ -304,18 +311,21 @@ PVGUI_Module::~PVGUI_Module()
     delete myInitTimer;
 }
 
-PARAVIS_ORB::PARAVIS_Gen_var PVGUI_Module::GetCPPEngine()
+PVViewer_EngineWrapper * PVGUI_Module::GetEngine()
 {
-  // initialize PARAVIS module engine (load, if necessary)
-  if ( CORBA::is_nil( MyEngine ) ) {
-      Engines::EngineComponent_var comp =
-          SalomeApp_Application::lcc()->FindOrLoad_Component( "FactoryServer", "PARAVIS" );
-      MyEngine = PARAVIS_ORB::PARAVIS_Gen::_narrow( comp );
-  }
-  return MyEngine;
+  return PVViewer_EngineWrapper::GetInstance();
 }
 
 
+/*!
+  \brief Create data model.
+  \return module specific data model
+*/
+CAM_DataModel* PVGUI_Module::createDataModel()
+{
+  return new PVGUI_DataModel( this );
+}
+
 pqPVApplicationCore * PVGUI_Module::GetPVApplication()
 {
   return PVViewer_ViewManager::GetPVApplication();
@@ -327,7 +337,7 @@ pqPVApplicationCore * PVGUI_Module::GetPVApplication()
 */
 void PVGUI_Module::initialize( CAM_Application* app )
 {
-  SalomeApp_Module::initialize( app );
+  LightApp_Module::initialize( app );
 
   // Create ParaViS actions
   createActions();
@@ -343,12 +353,12 @@ void PVGUI_Module::initialize( CAM_Application* app )
   }
   */
 
-  SalomeApp_Application* anApp = getApp();
+  LightApp_Application* anApp = getApp();
   SUIT_Desktop* aDesktop = anApp->desktop();
 
   // Initialize ParaView client and associated behaviors
   // and connect to externally launched pvserver
-  PVViewer_ViewManager::ParaviewInitApp(aDesktop);
+  PVViewer_ViewManager::ParaviewInitApp(aDesktop, anApp->logWindow());
   myGuiElements = PVViewer_GUIElements::GetInstance(aDesktop);
 
   // Remember current state of desktop toolbars
@@ -414,7 +424,7 @@ void PVGUI_Module::initialize( CAM_Application* app )
   updateMacros();
  
   SUIT_ResourceMgr* aResourceMgr = SUIT_Session::session()->resourceMgr();
-  bool isStop = aResourceMgr->booleanValue( "PARAVIS", "stop_trace", false );
+  bool isStop = aResourceMgr->booleanValue( PARAVIS_MODULE_NAME, "stop_trace", false );
   if(!isStop)
     {
       // Start a timer to schedule asap:
@@ -524,11 +534,11 @@ void PVGUI_Module::windows( QMap<int, int>& m ) const
 */
 void PVGUI_Module::showView( bool toShow )
 {
-  SalomeApp_Application* anApp = getApp();
+  LightApp_Application* anApp = getApp();
   PVViewer_ViewManager* viewMgr =
     dynamic_cast<PVViewer_ViewManager*>( anApp->getViewManager( PVViewer_Viewer::Type(), false ) );
   if ( !viewMgr ) {
-    viewMgr = new PVViewer_ViewManager( anApp->activeStudy(), anApp->desktop() );
+    viewMgr = new PVViewer_ViewManager( anApp->activeStudy(), anApp->desktop(), anApp->logWindow() );
     anApp->addViewManager( viewMgr );
     connect( viewMgr, SIGNAL( lastViewClosed( SUIT_ViewManager* ) ),
              anApp, SLOT( onCloseView( SUIT_ViewManager* ) ) );
@@ -612,7 +622,7 @@ bool PVGUI_Module::activateModule( SUIT_Study* study )
 
   storeCommonWindowsState();
 
-  bool isDone = SalomeApp_Module::activateModule( study );
+  bool isDone = LightApp_Module::activateModule( study );
   if ( !isDone ) return false;
 
   showView( true );
@@ -653,7 +663,7 @@ bool PVGUI_Module::activateModule( SUIT_Study* study )
 
   if ( myRecentMenuId != -1 ) menuMgr()->show(myRecentMenuId);
 
-  ClientFindOrCreateParavisComponent(PARAVIS::GetCStudy(this));
+  //ClientFindOrCreateParavisComponent(PARAVIS::GetCStudy(this));
 
   return isDone;
 }
@@ -714,7 +724,7 @@ bool PVGUI_Module::deactivateModule( SUIT_Study* study )
 
   restoreCommonWindowsState();
   
-  return SalomeApp_Module::deactivateModule( study );
+  return LightApp_Module::deactivateModule( study );
 }
 
 
@@ -762,7 +772,7 @@ void PVGUI_Module::studyClosed(SUIT_Study* study)
 {
   clearParaviewState();
 
-  SalomeApp_Module::studyClosed(study);
+  LightApp_Module::studyClosed(study);
 }
 
 /*!
@@ -774,9 +784,9 @@ void PVGUI_Module::onModelOpened()
   if(!studyDS) {
     return;
   }
-  
-  _PTR(SComponent) paravisComp = 
-    studyDS->FindComponent(GetCPPEngine()->ComponentDataType());
+
+  _PTR(SComponent) paravisComp =
+    studyDS->FindComponent(PARAVIS_MODULE_NAME);
   if(!paravisComp) {
     return;
   }
@@ -796,12 +806,13 @@ void PVGUI_Module::onModelOpened()
 }
 
 /*!
-  \brief Returns IOR of current engine
+\brief Returns IOR of current engine
 */
 QString PVGUI_Module::engineIOR() const
 {
-  CORBA::String_var anIOR = GetCPPEngine()->GetIOR();
-  return QString(anIOR.in());
+//  CORBA::String_var anIOR = GetCPPEngine()->GetIOR();
+//  return QString(anIOR.in());
+  return QString("");
 }
 
 /*!
@@ -971,18 +982,18 @@ void PVGUI_Module::createPreferences()
 {
   // Paraview settings tab
   int aParaViewSettingsTab = addPreference( tr( "TIT_PVIEWSETTINGS" ) );
-  int aPanel = addPreference(QString(), aParaViewSettingsTab, LightApp_Preferences::UserDefined, "PARAVIS", "");
+  int aPanel = addPreference(QString(), aParaViewSettingsTab, LightApp_Preferences::UserDefined, PARAVIS_MODULE_NAME, "");
   setPreferenceProperty(aPanel, "content", (qint64)(new PVGUI_ParaViewSettingsPane()));
 
   // Paravis settings tab
   int aParaVisSettingsTab = addPreference( tr( "TIT_PVISSETTINGS" ) );
-  addPreference( tr( "PREF_STOP_TRACE" ), aParaVisSettingsTab, LightApp_Preferences::Bool, "PARAVIS", "stop_trace");
+  addPreference( tr( "PREF_STOP_TRACE" ), aParaVisSettingsTab, LightApp_Preferences::Bool, PARAVIS_MODULE_NAME, "stop_trace");
 
-  addPreference( tr( "PREF_NO_EXT_PVSERVER" ), aParaVisSettingsTab, LightApp_Preferences::Bool, "PARAVIS", "no_ext_pv_server");
+  addPreference( tr( "PREF_NO_EXT_PVSERVER" ), aParaVisSettingsTab, LightApp_Preferences::Bool, PARAVIS_MODULE_NAME, "no_ext_pv_server");
 
   int aSaveType = addPreference(tr( "PREF_SAVE_TYPE_LBL" ), aParaVisSettingsTab,
                                 LightApp_Preferences::Selector,
-                                "PARAVIS", "savestate_type");
+                                PARAVIS_MODULE_NAME, "savestate_type");
   QList<QVariant> aIndices;
   QStringList aStrings;
   aIndices<<0<<1<<2;
@@ -998,8 +1009,8 @@ void PVGUI_Module::createPreferences()
 */
 void PVGUI_Module::contextMenuPopup(const QString& theClient, QMenu* theMenu, QString& theTitle)
 {
-  SalomeApp_Module::contextMenuPopup(theClient, theMenu, theTitle);
-  
+  LightApp_Module::contextMenuPopup(theClient, theMenu, theTitle);
+
   // Check if we are in Object Browser
   SUIT_DataBrowser* ob = getApp()->objectBrowser();
   bool isOBClient = (ob && theClient == ob->popupClientType());
@@ -1013,22 +1024,22 @@ void PVGUI_Module::contextMenuPopup(const QString& theClient, QMenu* theMenu, QS
   aSelectionMgr->selectedObjects(aListIO);
   if (aListIO.Extent() == 1 && aListIO.First()->hasEntry()) {
     QString entry = QString(aListIO.First()->getEntry());
-    
+
     // Get active study
-    SalomeApp_Study* activeStudy = 
+    SalomeApp_Study* activeStudy =
       dynamic_cast<SalomeApp_Study*>(getApp()->activeStudy());
     if(!activeStudy) {
       return;
     }
 
-    // Get SALOMEDS client study 
+    // Get SALOMEDS client study
     _PTR(Study) studyDS = activeStudy->studyDS();
     if(!studyDS) {
       return;
     }
 
-    QString paravisDataType(GetCPPEngine()->ComponentDataType());
-    if(activeStudy && activeStudy->isComponent(entry) && 
+    QString paravisDataType(PARAVIS_MODULE_NAME);
+    if(activeStudy && activeStudy->isComponent(entry) &&
        activeStudy->componentDataType(entry) == paravisDataType) {
       // ParaViS module object
       theMenu->addSeparator();
@@ -1036,12 +1047,12 @@ void PVGUI_Module::contextMenuPopup(const QString& theClient, QMenu* theMenu, QS
     }
     else {
       // Try to get state object
-      _PTR(SObject) stateSObj = 
+      _PTR(SObject) stateSObj =
           studyDS->FindObjectID(entry.toLatin1().constData());
       if (!stateSObj) {
           return;
       }
-      
+
       // Check local id
       _PTR(GenericAttribute) anAttr;
       if (!stateSObj->FindAttribute(anAttr, "AttributeLocalID")) {
@@ -1049,7 +1060,7 @@ void PVGUI_Module::contextMenuPopup(const QString& theClient, QMenu* theMenu, QS
       }
 
       _PTR(AttributeLocalID) anID(anAttr);
-      
+
       if (anID->Value() == PVSTATEID) {
         // Paraview state object
         theMenu->addSeparator();
@@ -1099,9 +1110,9 @@ void PVGUI_Module::onSaveMultiState()
   if(!studyDS) {
     return;
   }
-  
+
   _PTR(SComponent) paravisComp = 
-    studyDS->FindComponent(GetCPPEngine()->ComponentDataType());
+      studyDS->FindComponent(PARAVIS_MODULE_NAME);
   if(!paravisComp) {
     return;
   }
@@ -1267,8 +1278,8 @@ void PVGUI_Module::onDelete()
 
 void PVGUI_Module::onPushTraceTimer()
 {
-//  MESSAGE("onPushTraceTimer(): Pushing trace to engine...");
-  GetCPPEngine()->PutPythonTraceStringToEngine(getTraceString().toStdString().c_str());
+  //MESSAGE("onPushTraceTimer(): Pushing trace to engine...");
+  GetEngine()->PutPythonTraceStringToEngine(getTraceString().toStdString().c_str());
 }
 
 /*!
index c6b608a73edfe7329ac4bffa8207b1230ee6b358..b5e93b96d835c19aedc69b4c06b7c8c2dfe35337 100644 (file)
@@ -50,6 +50,7 @@ class pqPVApplicationCore;
 class pqDataRepresentation;
 class pqRepresentation;
 class PVViewer_GUIElements;
+class PVViewer_EngineWrapper;
 
 class PVGUI_Module : public SalomeApp_Module
 {
@@ -145,7 +146,7 @@ public:
   virtual void           initialize( CAM_Application* );
   virtual void           windows( QMap<int, int>& ) const;
 
-  virtual QString engineIOR() const;
+  virtual QString engineIOR() const;  // to be removed when becoming Light
 
   void openFile(const char* theName);
   void executeScript(const char *script);
@@ -164,10 +165,11 @@ public:
 
   virtual void contextMenuPopup(const QString& theClient, QMenu* theMenu, QString& theTitle);
 
-  // Get the unwrapped version of the engine - compare with PVViewer_EngineWrapper.
-  inline static PARAVIS_ORB::PARAVIS_Gen_var GetCPPEngine();
+  inline static PVViewer_EngineWrapper * GetEngine();
   inline static pqPVApplicationCore * GetPVApplication();
 
+  virtual CAM_DataModel* createDataModel();
+
 public slots:
   //void onImportFromVisu(QString theEntry);
 
index 42adaf84bbb4f88402d466c1e36d51e53a7eddaf..69411dae688c5e1170664bf2d9528ddca46c1e24 100644 (file)
@@ -31,7 +31,7 @@
 #include <SUIT_Desktop.h>
 #include <SUIT_ResourceMgr.h>
 #include <SUIT_Session.h>
-#include <SalomeApp_Application.h>
+#include <SalomeApp_Application.h>  // should ultimately be a LightApp only
 #include <LightApp_Application.h>
 
 #include <QAction>
@@ -551,7 +551,8 @@ void PVGUI_Module::pvCreateToolBars()
 QMenu* PVGUI_Module::getMenu( const int id )
 {
   QMenu* res = 0;
-  SalomeApp_Application* anApp = getApp();
+  //SalomeApp_Application* anApp = getApp();
+  LightApp_Application* anApp = getApp();
   SUIT_Desktop* desk = anApp->desktop();
   if ( desk ){
     QtxActionMenuMgr* menuMgr = desk->menuMgr();
index 8a5c767335ce4216f9d46d1c44f998632c6c999f..e438a97d997a69ea83bd7995a2e38b5deee1136e 100644 (file)
@@ -28,7 +28,7 @@
 
 #include <QtxActionToolMgr.h>
 #include <LightApp_Application.h>
-#include <SalomeApp_Application.h>
+#include <SalomeApp_Application.h>   // // should ultimately be a LightApp only
 #include <SUIT_Desktop.h>
 
 #include <QApplication>
@@ -105,6 +105,7 @@ void PVGUI_Module::setupDockWidgets()
  
   desk->setCorner(Qt::BottomLeftCorner, Qt::LeftDockWidgetArea);
   desk->setCorner(Qt::BottomRightCorner, Qt::RightDockWidgetArea);
+  desk->setTabPosition(Qt::LeftDockWidgetArea, QTabWidget::North);
 
   // Pipeline
   QDockWidget* pipelineBrowserDock = new QDockWidget( tr( "TTL_PIPELINE_BROWSER" ), desk );
@@ -137,7 +138,7 @@ void PVGUI_Module::setupDockWidgets()
 
   QWidget* informationWidgetFrame = new QWidget(informationDock);
   informationWidgetFrame->setObjectName("informationWidgetFrame");
-  
+
   QVBoxLayout* verticalLayout_2 = new QVBoxLayout(informationWidgetFrame);
   verticalLayout_2->setSpacing(0);
   verticalLayout_2->setContentsMargins(0, 0, 0, 0);
@@ -156,7 +157,7 @@ void PVGUI_Module::setupDockWidgets()
 
   myDockWidgets[informationDock] = true;
 
-  desk->setTabPosition(Qt::LeftDockWidgetArea, QTabWidget::North);
+
   desk->tabifyDockWidget(informationDock, propertiesDock);
   desk->tabifyDockWidget(propertiesDock, pipelineBrowserDock);
   //propertiesDock->raise();
@@ -263,8 +264,8 @@ void PVGUI_Module::setupDockWidgets()
   aProgress->setEnabled(true);
 
   // Set up the dock window corners to give the vertical docks more room.
-  desk->setCorner(Qt::BottomLeftCorner, Qt::LeftDockWidgetArea);
-  desk->setCorner(Qt::BottomRightCorner, Qt::RightDockWidgetArea);
+//  desk->setCorner(Qt::BottomLeftCorner, Qt::LeftDockWidgetArea);
+//  desk->setCorner(Qt::BottomRightCorner, Qt::RightDockWidgetArea);
 
   // Setup the default dock configuration ...
   statisticsViewDock->hide();
@@ -384,12 +385,15 @@ void PVGUI_Module::storeCommonWindowsState() {
   //     restoreCommonWindowsState() method, and at the moment of the ParaVis activation we call 
   //     this method.
 
+  //LightApp_Application* anApp = getApp();
   SalomeApp_Application* anApp = getApp();
   if(!anApp)
     return;
 
-  int begin = SalomeApp_Application::WT_ObjectBrowser;
-  int end = SalomeApp_Application::WT_NoteBook;
+//  int begin = SalomeApp_Application::WT_ObjectBrowser;
+//  int end = SalomeApp_Application::WT_NoteBook;
+  int begin = LightApp_Application::WT_ObjectBrowser;
+  int end = LightApp_Application::WT_User;
   for( int i = begin; i <= end; i++ ) {
     QWidget* wg = anApp->getWindow(i);
     if(wg) {
@@ -415,6 +419,7 @@ void PVGUI_Module::storeCommonWindowsState() {
 */
 void PVGUI_Module::restoreCommonWindowsState() {
   SalomeApp_Application* anApp = getApp();
+//  LightApp_Application* anApp = getApp();
   if(!anApp)
     return;
   DockWindowMap::const_iterator it = myCommonMap.begin();