Switched to using True/False in the wxPython lib and demo instead of
true/false or TRUE/FALSE to prepare for the new boolean type and constants being added to Python. Added code to wx.py to test for the existence of the new constants and to create suitable values if not present. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/branches/WX_2_4_BRANCH@19335 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -67,7 +67,7 @@ class TestPanel( wxPanel ):
|
||||
|
||||
for radio, text in self.group1_ctrls + self.group2_ctrls:
|
||||
radio.SetValue(0)
|
||||
text.Enable(FALSE)
|
||||
text.Enable(False)
|
||||
|
||||
|
||||
def OnGroup1Select( self, event ):
|
||||
@@ -75,18 +75,18 @@ class TestPanel( wxPanel ):
|
||||
self.log.write('Group1 %s selected\n' % radio_selected.GetLabel() )
|
||||
for radio, text in self.group1_ctrls:
|
||||
if radio is radio_selected:
|
||||
text.Enable(TRUE)
|
||||
text.Enable(True)
|
||||
else:
|
||||
text.Enable(FALSE)
|
||||
text.Enable(False)
|
||||
|
||||
def OnGroup2Select( self, event ):
|
||||
radio_selected = event.GetEventObject()
|
||||
self.log.write('Group2 %s selected\n' % radio_selected.GetLabel() )
|
||||
for radio, text in self.group2_ctrls:
|
||||
if radio is radio_selected:
|
||||
text.Enable(TRUE)
|
||||
text.Enable(True)
|
||||
else:
|
||||
text.Enable(FALSE)
|
||||
text.Enable(False)
|
||||
|
||||
#----------------------------------------------------------------------
|
||||
|
||||
|
Reference in New Issue
Block a user