From: prascle Date: Tue, 9 Apr 2013 14:51:29 +0000 (+0000) Subject: PR: improve compatibilty with old scripts X-Git-Tag: V7_2_0~18 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=5f237094e9ae0a2515235952b19804136cd0d841;p=modules%2Fgeom.git PR: improve compatibilty with old scripts --- diff --git a/src/GEOM_SWIG/geompy.py b/src/GEOM_SWIG/geompy.py index 75bbe7a88..a84a87dd2 100644 --- a/src/GEOM_SWIG/geompy.py +++ b/src/GEOM_SWIG/geompy.py @@ -29,6 +29,8 @@ import salome from salome.geom import geomBuilder from salome import * +import GEOM +from salome.geom.geomBuilder import info, PackData, ReadTexture, EnumToLong # retrieve GEOM engine in try/except block # to avoid problems in some cases, e.g. when generating documentation @@ -43,9 +45,11 @@ try: globals()[k] = getattr( geom, k ) pass del k - from geomBuilder import ShapeType, GEOM, kind, info, PackData, ReadTexture, EnumToLong + ShapeType = geom.ShapeType + kind = geom.kind pass except: + print "exception in geompy.py" geom = None pass