]> git.saurik.com Git - wxWidgets.git/commitdiff
avoid populating the array with NULL controls during creation (SetWindowVariant calli...
authorStefan Csomor <csomor@advancedconcepts.ch>
Wed, 26 Jan 2011 15:52:41 +0000 (15:52 +0000)
committerStefan Csomor <csomor@advancedconcepts.ch>
Wed, 26 Jan 2011 15:52:41 +0000 (15:52 +0000)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@66771 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

src/generic/datectlg.cpp

index 2ebe9c7c4b601f744a59d71ca0f734546c9b0188..3e6d041eb511571811ee04c178043d5501833cca 100644 (file)
@@ -381,8 +381,10 @@ wxSize wxDatePickerCtrlGeneric::DoGetBestSize() const
 wxWindowList wxDatePickerCtrlGeneric::GetCompositeWindowParts() const
 {
     wxWindowList parts;
-    parts.push_back(m_combo);
-    parts.push_back(m_popup);
+    if (m_combo)
+        parts.push_back(m_combo);
+    if (m_popup)
+        parts.push_back(m_popup);
     return parts;
 }