]> git.saurik.com Git - wxWidgets.git/blobdiff - src/msw/bmpcbox.cpp
On OSX don't propogate the alignment setting from column to renderer if it is a custo...
[wxWidgets.git] / src / msw / bmpcbox.cpp
index 19a5d3a050b53395d4a9fc2f209643247e092708..3ad1855abfb8e7b0a6b5ba2d001f10bf63036727 100644 (file)
@@ -140,7 +140,7 @@ void wxBitmapComboBox::RecreateControl()
     DissociateHandle();
     ::DestroyWindow(hwnd);
 
-    if ( !MSWCreateControl(wxT("COMBOBOX"), value, pos, size) )
+    if ( !MSWCreateControl(wxT("COMBOBOX"), wxEmptyString, pos, size) )
         return;
 
     // initialize the controls contents
@@ -179,6 +179,10 @@ void wxBitmapComboBox::RecreateControl()
     }
 
     ::SendMessage(GetHwnd(), CB_SETITEMHEIGHT, 0, MeasureItem(0));
+
+    // Revert the old string value
+    if ( !HasFlag(wxCB_READONLY) )
+        ChangeValue(value);
 }
 
 wxBitmapComboBox::~wxBitmapComboBox()