]> git.saurik.com Git - wxWidgets.git/blobdiff - samples/combo/combo.cpp
include fixes
[wxWidgets.git] / samples / combo / combo.cpp
index a136903a679e3b1746c70d81791daced1517250a..5f8e7fea591c87fcaeeac2dcf82873aa8f80d9be 100644 (file)
@@ -228,8 +228,10 @@ public:
                                    int item, int flags ) const
     {
 
-        // If item is selected or even, use the default rendering.
+        // If item is selected or even, or we are painting the
+        // combo control itself, use the default rendering.
         if ( GetVListBoxComboPopup()->IsCurrent((size_t)item) ||
+             (flags & wxODCB_PAINTING_CONTROL) ||
              (item & 1) == 0 )
         {
             wxOwnerDrawnComboBox::OnDrawBackground(dc,rect,item,flags);