]> git.saurik.com Git - wxWidgets.git/blobdiff - src/msw/statbox.cpp
setting foreground colour for wxCheckBox now works when using XP themes too
[wxWidgets.git] / src / msw / statbox.cpp
index 88e485e64b57e19ecc41ab01e546dedf816c041c..42fec06f706bf3d497b040b47268847e213b8c6f 100644 (file)
@@ -146,9 +146,11 @@ WXDWORD wxStaticBox::MSWGetStyle(long style, WXDWORD *exstyle) const
 
     if ( exstyle )
     {
+#ifndef __WXWINCE__
         if (wxSystemOptions::IsFalse(wxT("msw.staticbox.optimized-paint")))
             *exstyle = WS_EX_TRANSPARENT;
         else
+#endif
             *exstyle = 0;
     }
 
@@ -166,7 +168,9 @@ wxSize wxStaticBox::DoGetBestSize() const
     wBox += 3*cx;
     int hBox = EDIT_HEIGHT_FROM_CHAR_HEIGHT(cy);
 
-    return wxSize(wBox, hBox);
+    wxSize best(wBox, hBox);
+    CacheBestSize(best);
+    return best;
 }
 
 void wxStaticBox::GetBordersForSizer(int *borderTop, int *borderOther) const