]> git.saurik.com Git - wxWidgets.git/commitdiff
Allow small widths if setting initial strings.
authorJulian Smart <julian@anthemion.co.uk>
Mon, 4 Aug 2008 15:32:34 +0000 (15:32 +0000)
committerJulian Smart <julian@anthemion.co.uk>
Mon, 4 Aug 2008 15:32:34 +0000 (15:32 +0000)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@54966 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

src/gtk/choice.cpp

index 2427fdc73f11109706218ead2515511fdea39aae..97129ba2f1e5652eb08ac46d8c492375ee806d77 100644 (file)
@@ -350,7 +350,7 @@ wxSize wxChoice::DoGetBestSize() const
     // in the combobox
     if ( m_widget )
     {
-        ret.x = 60;  // start with something "sensible"
+        ret.x = GetCount() > 0 ? 0 : 60;  // start with something "sensible"
         int width;
         unsigned int count = GetCount();
         for ( unsigned int n = 0; n < count; n++ )