self.OnChangeMonth()
def OnButton(self, evt):
- self.cal.Destroy()
- self.cal = None
+ if self.cal is not None:
+ self.cal.Destroy()
+ self.cal = None
def OnCalSelected(self, evt):
self.log.write('OnCalSelected: %s\n' % evt.GetDate())
if __name__ == '__main__':
import sys,os
import run
- run.main(['', os.path.basename(sys.argv[0])])
+ run.main(['', os.path.basename(sys.argv[0])] + sys.argv[1:])