import wx
import images
class App(wx.App):
def __init__(self, redirect=True, filename=None):
wx.App.__init__(self, redirect, filename)
def OnInit(self):
dlg = wx.SingleChoiceDialog(None,
'What version of Python are you using?', 'Single Choice',
['1.5.2', '2.0', '2.1.3', '2.2', '2.3.1'])
if dlg.ShowModal() == wx.ID_OK:
response = dlg.GetStringSelection()
dlg.Destroy()
return True
app = App(False, "output")
fred = app.MainLoop()
|