avoid populating the array with NULL controls during creation (SetWindowVariant calling SetFont crashing)

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@66771 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Stefan Csomor
2011-01-26 15:52:41 +00:00
parent 99eb484a70
commit 809d69287e

View File

@@ -381,8 +381,10 @@ wxSize wxDatePickerCtrlGeneric::DoGetBestSize() const
wxWindowList wxDatePickerCtrlGeneric::GetCompositeWindowParts() const wxWindowList wxDatePickerCtrlGeneric::GetCompositeWindowParts() const
{ {
wxWindowList parts; wxWindowList parts;
parts.push_back(m_combo); if (m_combo)
parts.push_back(m_popup); parts.push_back(m_combo);
if (m_popup)
parts.push_back(m_popup);
return parts; return parts;
} }