]> git.saurik.com Git - wxWidgets.git/blobdiff - wxPython/demo/MDISashDemo.py
Reorganized the tree in the wxPython demo, hooked the MDI demos into
[wxWidgets.git] / wxPython / demo / MDISashDemo.py
index 2e4258f48747e6c0dfe6268f905e3d5199d62fc2..4b2b08ffd745a8b1d5e612f82937ce6b96ac87ed 100644 (file)
@@ -125,16 +125,17 @@ class MyParentFrame(wxMDIParentFrame):
 
 #----------------------------------------------------------------------
 
-class MyApp(wxApp):
-    def OnInit(self):
-        frame = MyParentFrame()
-        frame.Show(true)
-        self.SetTopWindow(frame)
-        return true
+if __name__ == '__main__':
+    class MyApp(wxApp):
+        def OnInit(self):
+            frame = MyParentFrame()
+            frame.Show(true)
+            self.SetTopWindow(frame)
+            return true
 
 
-app = MyApp(0)
-app.MainLoop()
+    app = MyApp(0)
+    app.MainLoop()