]> git.saurik.com Git - wxWidgets.git/blobdiff - src/common/ownerdrwcmn.cpp
Fix typo in last commit
[wxWidgets.git] / src / common / ownerdrwcmn.cpp
index 28ebb7b1e5a8b64e650d66789f38330c49fb6180..29e646a163f037fa8705325c96e148197d0ff978 100644 (file)
@@ -86,9 +86,18 @@ void wxOwnerDrawnBase::GetColourToUse(wxODStatus stat, wxColour& colText, wxColo
     else
     {
         // fall back to default colors if none explicitly specified
     else
     {
         // fall back to default colors if none explicitly specified
-        colText = m_colText.Ok() ? m_colText
-                                 : wxSystemSettings::GetColour(wxSYS_COLOUR_MENUTEXT);
-        colBack = m_colBack.Ok() ? m_colBack
+
+        if ( stat & wxODDisabled )
+        {
+            colText = wxSystemSettings::GetColour(wxSYS_COLOUR_GRAYTEXT);
+        }
+        else
+        {
+            colText = m_colText.IsOk() ? m_colText
+                                     : wxSystemSettings::GetColour(wxSYS_COLOUR_MENUTEXT);
+        }
+
+        colBack = m_colBack.IsOk() ? m_colBack
                                  : wxSystemSettings::GetColour(wxSYS_COLOUR_MENU);
     }
 }
                                  : wxSystemSettings::GetColour(wxSYS_COLOUR_MENU);
     }
 }