X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;f=src%2FSMESH_SWIG%2Fex24_cylinder.py;h=534f699d54243bd3af996c662a7ec76a405b9dd2;hb=ea6d39162cc87522ef869b97a6b4be8bd41776d5;hp=87b4cfbe0cd8486a3de616e0ee75f87c574a9da2;hpb=a1920ff31054e2c882bd94d4f3c04abe53980ce0;p=modules%2Fsmesh.git diff --git a/src/SMESH_SWIG/ex24_cylinder.py b/src/SMESH_SWIG/ex24_cylinder.py index 87b4cfbe0..534f699d5 100644 --- a/src/SMESH_SWIG/ex24_cylinder.py +++ b/src/SMESH_SWIG/ex24_cylinder.py @@ -1,5 +1,5 @@ # -*- coding: iso-8859-1 -*- -# Copyright (C) 2007-2016 CEA/DEN, EDF R&D, OPEN CASCADE +# Copyright (C) 2007-2020 CEA/DEN, EDF R&D, OPEN CASCADE # # This library is free software; you can redistribute it and/or # modify it under the terms of the GNU Lesser General Public @@ -26,11 +26,11 @@ import salome salome.salome_init() import GEOM from salome.geom import geomBuilder -geompy = geomBuilder.New(salome.myStudy) +geompy = geomBuilder.New() import SMESH, SALOMEDS from salome.smesh import smeshBuilder -smesh = smeshBuilder.New(salome.myStudy) +smesh = smeshBuilder.New() geo = geompy @@ -103,7 +103,7 @@ geompy.DifferenceList(group_1, [group_1_box]) # Mesh the blocks with hexahedral # ------------------------------- -smesh.SetCurrentStudy(salome.myStudy) +smesh.UpdateStudy() def discretize(x, y, z, n, s=blocks): p = geompy.MakeVertex(x, y, z) @@ -134,4 +134,4 @@ hexa.Group(group_1) # Update object browser # --------------------- -salome.sg.updateObjBrowser(True) +salome.sg.updateObjBrowser()