# -*- coding: iso-8859-1 -*-
-# Copyright (C) 2007-2016 CEA/DEN, EDF R&D, OPEN CASCADE
+# Copyright (C) 2007-2021 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
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()
# ---- define a box
mesh.Compute()
-salome.sg.updateObjBrowser(True)
+salome.sg.updateObjBrowser()
sg = salome.ImportComponentGUI('SMESH')
-if type(sg) != type(salome.salome_ComponentGUI):
+if not isinstance(sg, type(salome.salome_ComponentGUI)):
sg.CreateAndDisplayActor('0:1:2:3')