Commits

Lars Yencken committed 3084730

Adds a slot example to the demo.

Comments (0)

Files changed (1)

         'io',
         'progressBar',
         'shell',
+        'slot',
     ]
 
 #----------------------------------------------------------------------------#
 import consoleLog
 import progressBar
 from progressBar import withProgress
+import slot
 
 #----------------------------------------------------------------------------#
 
     log.log('Substep 3 with progress ', newLine=False)
     for i in withProgress(xrange(100)):
         sl(0.1)
+    log.start('Substep 4 with slot', nSteps=1)
+    log.log('', newLine=False)
+    s = slot.Slot() 
+    for j in xrange(637):
+        time.sleep(0.01)
+        if j % 100 == 0:
+            s.update(str(j))
+    s.finish(str(j))
+    log.finish()
+
     log.finish('Completed ok')
 
     log.log('Postprocessing step')