From: rnv Date: Wed, 7 Jun 2017 16:45:15 +0000 (+0300) Subject: Merge multi-study removal branch. X-Git-Tag: Before_python3_27062017~3 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=91a8c600c776245d1b67d9608986040e468c3798;p=modules%2Fparavis.git Merge multi-study removal branch. --- diff --git a/examples/command_line/dataset.py b/examples/command_line/dataset.py index cff4c01d..300af014 100644 --- a/examples/command_line/dataset.py +++ b/examples/command_line/dataset.py @@ -2,7 +2,7 @@ def create_geometry(out_filename=None): import GEOM import salome from salome.geom import geomBuilder - geompy = geomBuilder.New(salome.myStudy) + geompy = geomBuilder.New() # create a cloud of points points = [ @@ -29,7 +29,7 @@ def create_meshes(geometry, out_filename=None): import salome from salome.smesh import smeshBuilder - smesh = smeshBuilder.New(salome.myStudy) + smesh = smeshBuilder.New() Mesh_tri = smesh.Mesh(geometry) Regular_1D = Mesh_tri.Segment() diff --git a/resources/PARAVISCatalog.xml.in b/resources/PARAVISCatalog.xml.in index e827c058..7db311a4 100644 --- a/resources/PARAVISCatalog.xml.in +++ b/resources/PARAVISCatalog.xml.in @@ -32,7 +32,6 @@ vsv @SALOMEPARAVIS_VERSION@ PVServer control service - 1 1 pqAppIcon22.png diff --git a/src/Macro/ShowSalomeObject.py b/src/Macro/ShowSalomeObject.py index e7c417dc..464519d3 100644 --- a/src/Macro/ShowSalomeObject.py +++ b/src/Macro/ShowSalomeObject.py @@ -44,7 +44,7 @@ for entry in selection: try: import GEOM from salome.geom import geomBuilder - geompy = geomBuilder.New(salome.myStudy) + geompy = geomBuilder.New() go = sobj.GetObject()._narrow(GEOM.GEOM_Object) if go: tmpf = tempfile.NamedTemporaryFile(suffix='.vtk') @@ -64,7 +64,7 @@ for entry in selection: try: import SMESH from salome.smesh import smeshBuilder - mesh = smeshBuilder.New(salome.myStudy) + mesh = smeshBuilder.New() mo = sobj.GetObject()._narrow(SMESH.SMESH_Mesh) if mo: tmpf = tempfile.NamedTemporaryFile(suffix='.med') diff --git a/src/PVGUI/PVGUI_DataModel.cxx b/src/PVGUI/PVGUI_DataModel.cxx index 8f4805fc..9e321776 100644 --- a/src/PVGUI/PVGUI_DataModel.cxx +++ b/src/PVGUI/PVGUI_DataModel.cxx @@ -208,7 +208,7 @@ bool PVGUI_DataModel::dumpPython( const QString& path, CAM_Study* std, if (isMultiFile) { QStringList abuffer; - abuffer.push_back(QString("def RebuildData( theStudy ):")); + abuffer.push_back(QString("def RebuildData():")); QStringList lst(trace.split("\n")); foreach(QString elem, lst) { diff --git a/test/VisuPrs/bugs/A5.py b/test/VisuPrs/bugs/A5.py index 357194dc..8fd805eb 100644 --- a/test/VisuPrs/bugs/A5.py +++ b/test/VisuPrs/bugs/A5.py @@ -28,7 +28,6 @@ import pvsimple salome.salome_init() myStudy = salome.myStudy -myStudyManager = salome.myStudyManager data_file = datadir + "TimeStamps.med" @@ -41,11 +40,9 @@ save_file = os.path.join(tmp_dir, "TimeStamps_save.hdf") print "Save to file ", save_file pvsimple.OpenDataFile(data_file) -myStudyManager.SaveAs(save_file, myStudy, 0) -myStudyManager.Close(myStudy) +myStudy.SaveAs(save_file, 0, 0) -openedStudy = myStudyManager.Open(data_file) -myStudyManager.Close(openedStudy) +myStudy.Open(data_file) os.remove(save_file) diff --git a/test/VisuPrs/dump_study/B5.py b/test/VisuPrs/dump_study/B5.py index cd54ea55..9a93f24c 100644 --- a/test/VisuPrs/dump_study/B5.py +++ b/test/VisuPrs/dump_study/B5.py @@ -42,11 +42,9 @@ import salome # run Salome #salome_session = SalomeSession() salome.salome_init() -salome.myStudyManager.Close(salome.myStudy) file_name = os.path.join(os.path.dirname(sys.argv[0]), "test1.hdf") -opened_study = salome.myStudyManager.Open(file_name) -salome.myStudy = opened_study +salome.myStudy.Open(file_name) # 3. Find IsoSurfaces from pvsimple import *