X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;f=src%2FPythonAddons%2Faddons_Features.py;h=e2271d2242a9ef5db3e25ed49934c2e085559dcc;hb=refs%2Fheads%2FV9_11_BR;hp=50f82085613d827d7c11ab3f21fe9c2ed81fba0e;hpb=6e421e939851e0de46554ae45a3ca0e1f67cd91d;p=modules%2Fshaper.git diff --git a/src/PythonAddons/addons_Features.py b/src/PythonAddons/addons_Features.py old mode 100644 new mode 100755 index 50f820856..e2271d224 --- a/src/PythonAddons/addons_Features.py +++ b/src/PythonAddons/addons_Features.py @@ -1,4 +1,4 @@ -# Copyright (C) 2014-2019 CEA/DEN, EDF R&D +# Copyright (C) 2014-2023 CEA, EDF # # This library is free software; you can redistribute it and/or # modify it under the terms of the GNU Lesser General Public @@ -17,12 +17,13 @@ # See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com # -"""Registration of all user-defined Python features -""" +"""Registration of all user-defined Python features""" import ModelAPI -from macros.box.feature import BoxFeature from macros.rectangle.feature import SketchPlugin_Rectangle +from macros.compoundVertices.feature import compoundVertices +from macros.importParameters.feature import importParameters +from macros.pipeNetwork.feature import pipeNetwork class PythonFeaturesPlugin(ModelAPI.ModelAPI_Plugin): @@ -42,12 +43,14 @@ class PythonFeaturesPlugin(ModelAPI.ModelAPI_Plugin): """Override ModelAPI_Plugin.createFeature()""" aFeature = None - if theFeatureID == BoxFeature.ID(): - aFeature = BoxFeature().__disown__() - - elif theFeatureID == SketchPlugin_Rectangle.ID(): + if theFeatureID == SketchPlugin_Rectangle.ID(): aFeature = SketchPlugin_Rectangle().__disown__() - + elif theFeatureID == compoundVertices.ID(): + aFeature = compoundVertices().__disown__() + elif theFeatureID == importParameters.ID(): + aFeature = importParameters().__disown__() + elif theFeatureID == pipeNetwork.ID(): + aFeature = pipeNetwork().__disown__() else: raise Exception("No such feature %s" % theFeatureID)