From 58e041b75320b509fe01cfb9d7057990e4a60f04 Mon Sep 17 00:00:00 2001 From: Vadim Zeitlin Date: Sun, 22 May 2005 22:17:47 +0000 Subject: [PATCH] fix assert when leaving control with wxDP_ALLOWNONE style (patch 1190145) git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@34275 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- src/generic/datectlg.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/generic/datectlg.cpp b/src/generic/datectlg.cpp index b088654129..299aec46f7 100644 --- a/src/generic/datectlg.cpp +++ b/src/generic/datectlg.cpp @@ -867,7 +867,7 @@ void wxDatePickerCtrlGeneric::OnKillFocus(wxFocusEvent &ev) m_txt->SetValue(wxEmptyString); // notify that we had to change the date after validation - if ( (dt.IsValid() && m_currentDate != dt) || + if ( (dt.IsValid() && (!m_currentDate.IsValid() || m_currentDate != dt)) || (!dt.IsValid() && m_currentDate.IsValid()) ) { m_currentDate = dt; -- 2.45.2