]> git.saurik.com Git - wxWidgets.git/commitdiff
Use GetBackgroundColour so it will revert to the default if
authorRobin Dunn <robin@alldunn.com>
Thu, 17 Jun 2004 22:50:54 +0000 (22:50 +0000)
committerRobin Dunn <robin@alldunn.com>
Thu, 17 Jun 2004 22:50:54 +0000 (22:50 +0000)
wxNullColour is used

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@27870 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

src/mac/carbon/window.cpp

index 9088d2f57aadb9b31a9b0c0c5be9ed79d09fa5c8..35913c0d0c2142afbbc5c81d5379bdd9e150a42b 100644 (file)
@@ -918,17 +918,18 @@ bool wxWindowMac::SetBackgroundColour(const wxColour& col )
         return false ;
 
     wxBrush brush ;
-    if ( col == wxSystemSettings::GetColour(wxSYS_COLOUR_APPWORKSPACE) )
+    wxColour newCol(GetBackgroundColour());
+    if ( newCol == wxSystemSettings::GetColour(wxSYS_COLOUR_APPWORKSPACE) )
     {
         brush.MacSetTheme( kThemeBrushDocumentWindowBackground ) ;
     }
-    else if (  col == wxSystemSettings::GetColour(wxSYS_COLOUR_3DFACE ) )
+    else if (  newCol == wxSystemSettings::GetColour(wxSYS_COLOUR_3DFACE ) )
     {
         brush.MacSetTheme( kThemeBrushDialogBackgroundActive ) ; 
     } 
     else
     {
-        brush.SetColour( col ) ;
+        brush.SetColour( newCol ) ;
     }
     MacSetBackgroundBrush( brush ) ;