]> SALOME platform Git repositories - modules/visu.git/commitdiff
Salome HOME
DumpPytnon
authorouv <ouv@opencascade.com>
Fri, 12 Jan 2007 15:19:18 +0000 (15:19 +0000)
committerouv <ouv@opencascade.com>
Fri, 12 Jan 2007 15:19:18 +0000 (15:19 +0000)
src/VISU_SWIG/visu.py
src/VISU_SWIG/visu_change_input.py

index 15d5b7fe3907f0595d6c5a510fd73e5e4a02fd8e..7e7b0e713c106a3eb447341534ae77e9b9112e9b 100644 (file)
@@ -31,6 +31,7 @@ import SALOME
 import SALOME_Session_idl
 import SALOMEDS
 import SALOME_MED
+import SALOME_ModuleCatalog
 from omniORB import CORBA
 from string import *
 from time import sleep
@@ -77,7 +78,8 @@ def PublishComponent(theStudyDocument):
 
         aSComponent = aStudyBuilder.NewComponent(aComponentDataType);
         aName = aStudyBuilder.FindOrCreateAttribute(aSComponent,"AttributeName")
-        aModuleCatalog = myNamingService.Resolve("/Kernel/ModulCatalog");
+        aModuleCatalogObj = myNamingService.Resolve("/Kernel/ModulCatalog");
+        aModuleCatalog = aModuleCatalogObj._narrow(SALOME_ModuleCatalog.ModuleCatalog)
         aComponent = aModuleCatalog.GetComponent(aComponentDataType);
         if aComponent != None:
             aComponentUserName = aComponent._get_componentusername()
index 47f477f4d8f092cbe679654a135c5feca8ebfe01..44233a3c1301348522e01b6f3cfd60fab859b4aa 100644 (file)
@@ -42,7 +42,7 @@ def WalkTroughTimeStamps(theVISUType,
   aPrs3d.SetEntity(theEntity)
   aPrs3d.SetFieldName(theFieldName)
   aPrs3d.SetTimeStampNumber(theTimeStampNumber)
-  if not aPrs3d.Apply():
+  if not aPrs3d.Apply(0):
     print "It is impossible to create such kind of presentation (%s) with the given parameters" % theVISUType
     print "\ttheMeshName = '%s'" % theMeshName
     print "\ttheEntity = %s" % theEntity
@@ -60,7 +60,7 @@ def WalkTroughTimeStamps(theVISUType,
   for anInfo in aRange:
     print "%d (%s); " % (anInfo.myNumber, anInfo.myTime)
     aPrs3d.SetTimeStampNumber(anInfo.myNumber)
-    aPrs3d.Apply()
+    aPrs3d.Apply(0)
     aView.Update();
     time.sleep(aDelay)
     pass