X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/cf694132f1c28509a9f84377ce8d374bae4177ad..61243a510fe15e04996a986daaa53ed9fee75484:/utils/wxPython/demo/wxLayoutConstraints.py diff --git a/utils/wxPython/demo/wxLayoutConstraints.py b/utils/wxPython/demo/wxLayoutConstraints.py index 9182115d4c..8e63a12af2 100644 --- a/utils/wxPython/demo/wxLayoutConstraints.py +++ b/utils/wxPython/demo/wxLayoutConstraints.py @@ -3,14 +3,14 @@ from wxPython.wx import * #--------------------------------------------------------------------------- -class TestLayoutConstraints(wxWindow): +class TestLayoutConstraints(wxPanel): def __init__(self, parent): - wxWindow.__init__(self, parent, -1) - self.SetBackgroundColour(wxNamedColour("MEDIUM ORCHID")) - + wxPanel.__init__(self, parent, -1) self.SetAutoLayout(true) EVT_BUTTON(self, 100, self.OnButton) + self.SetBackgroundColour(wxNamedColour("MEDIUM ORCHID")) + self.panelA = wxWindow(self, -1, wxDefaultPosition, wxDefaultSize, wxSIMPLE_BORDER) self.panelA.SetBackgroundColour(wxBLUE) @@ -86,6 +86,8 @@ class TestLayoutConstraints(wxWindow): self.panelD.SetConstraints(lc); + + def OnButton(self, event): wxBell()