1. Anthony Tuininga
  2. cx_PyGenLib

Commits

Anthony Tuininga  committed 325f9a5

Add support for setting a "null" datetime object when needed.

  • Participants
  • Parent commits b39cc24
  • Branches default

Comments (0)

Files changed (1)

File ceGUI/SimpleControls.py

View file
                     wxDate.GetDay())
 
     def SetValue(self, value):
-        if value is not None:
+        if value is None:
+            wxDate = wx.DateTime()
+        else:
             wxDate = wx.DateTimeFromDMY(value.day, value.month - 1, value.year)
-            wx.DatePickerCtrl.SetValue(self, wxDate)
+        wx.DatePickerCtrl.SetValue(self, wxDate)
 
 
 class Notebook(BaseControl, wx.Notebook):