]> git.saurik.com Git - wxWidgets.git/blob - wxPython/demo/wxFrame.py
we now send iconize events
[wxWidgets.git] / wxPython / demo / wxFrame.py
1
2 from wxPython.wx import *
3
4 #---------------------------------------------------------------------------
5
6 class MyFrame(wxFrame):
7 def __init__(self, parent, ID, title, pos, size):
8 wxFrame.__init__(self, parent, ID, title, pos, size)
9 panel = wxPanel(self, -1)
10
11 button = wxButton(panel, 1003, "Close Me")
12 button.SetPosition(wxPoint(15, 15))
13 EVT_BUTTON(self, 1003, self.OnCloseMe)
14 EVT_CLOSE(self, self.OnCloseWindow)
15
16
17 def OnCloseMe(self, event):
18 self.Close(true)
19
20 def OnCloseWindow(self, event):
21 self.Destroy()
22
23 #---------------------------------------------------------------------------
24
25 def runTest(frame, nb, log):
26 win = MyFrame(frame, -1, "This is a wxFrame", wxDefaultPosition, wxSize(350, 200))
27 frame.otherWin = win
28 win.Show(true)
29
30
31 #---------------------------------------------------------------------------
32
33
34
35
36
37
38
39
40
41
42 overview = """\
43 """