]> git.saurik.com Git - wxWidgets.git/blobdiff - wxPython/demo/wxProgressDialog.py
merged 2.2 branch
[wxWidgets.git] / wxPython / demo / wxProgressDialog.py
diff --git a/wxPython/demo/wxProgressDialog.py b/wxPython/demo/wxProgressDialog.py
new file mode 100644 (file)
index 0000000..61caba2
--- /dev/null
@@ -0,0 +1,38 @@
+
+from wxPython.wx import *
+
+#---------------------------------------------------------------------------
+
+def runTest(frame, nb, log):
+    max = 20
+    dlg = wxProgressDialog("Progress dialog example",
+                           "An informative message",
+                           max,
+                           frame,
+                           wxPD_CAN_ABORT | wxPD_APP_MODAL)
+
+    keepGoing = true
+    count = 0
+    while keepGoing and count <= max:
+        count = count + 1
+        wxSleep(1)
+
+        if count == max / 2:
+            keepGoing = dlg.Update(count, "Half-time!")
+        else:
+            keepGoing = dlg.Update(count)
+
+    dlg.Destroy()
+
+
+#---------------------------------------------------------------------------
+
+
+
+
+
+
+
+
+overview = """\
+"""