From 477a7e26aafa1e7f755420b3176734f3fb3a6b86 Mon Sep 17 00:00:00 2001 From: asl Date: Mon, 14 Dec 2009 11:43:05 +0000 Subject: [PATCH] instance of Parameter can be passed into Geom objects --- src/KERNEL_PY/salome_notebook.py | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/src/KERNEL_PY/salome_notebook.py b/src/KERNEL_PY/salome_notebook.py index e4d37643f..e94c61ff0 100644 --- a/src/KERNEL_PY/salome_notebook.py +++ b/src/KERNEL_PY/salome_notebook.py @@ -78,8 +78,13 @@ class Notebook: """ Return value of the variable with name "variableName". """ + aParam = None aResult = None - aParam = self.myNotebook.GetParameter( variableName ) + if isinstance( variableName, str ): + aParam = self.myNotebook.GetParameter( variableName ) + elif isinstance( variableName, SALOME._objref_Parameter ): + aParam = variableName + if aParam != None: if aParam.GetType() == SALOME.TReal: -- 2.39.2