From 04f9d89bee5fd00c45ee27288eab1852eb8d29bd Mon Sep 17 00:00:00 2001 From: HomeWorld Date: Sun, 5 Sep 2010 22:09:38 +0300 Subject: [PATCH] TogglePanel: more tweaks (colour stuff) --- gui/pyfatogglepanel.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gui/pyfatogglepanel.py b/gui/pyfatogglepanel.py index 4845adba5..7fbbc875c 100644 --- a/gui/pyfatogglepanel.py +++ b/gui/pyfatogglepanel.py @@ -25,7 +25,7 @@ class TogglePanel ( wx.Panel ): self.SetSizer( self.mainSizer ) self.headerPanel = wx.Panel(self) - self.headerPanel.SetBackgroundColour( wx.SystemSettings.GetColour( wx.SYS_COLOUR_GRAYTEXT) ) +# self.headerPanel.SetBackgroundColour( wx.SystemSettings.GetColour( wx.SYS_COLOUR_GRAYTEXT) ) self.mainSizer.Add(self.headerPanel,0,wx.EXPAND,5) @@ -111,7 +111,7 @@ class TogglePanel ( wx.Panel ): bitmap = wx.EmptyBitmap(24, 24) dc = wx.MemoryDC() dc.SelectObject(bitmap) - dc.SetBackground(wx.TheBrushList.FindOrCreateBrush(self.headerPanel.GetBackgroundColour(), wx.SOLID)) + dc.SetBackground(wx.TheBrushList.FindOrCreateBrush(self.parent.GetBackgroundColour(), wx.SOLID)) dc.Clear() wx.RendererNative.Get().DrawTreeItemButton(self, dc, wx.Rect(0, 0, 24, 24), wx.CONTROL_EXPANDED if mode == "expanded" else 0) @@ -141,7 +141,7 @@ class TogglePanel ( wx.Panel ): def leaveWindow( self, event ): - self.headerPanel.SetBackgroundColour( wx.SystemSettings.GetColour( wx.SYS_COLOUR_GRAYTEXT ) ) + self.headerPanel.SetBackgroundColour( self.parent.GetBackgroundColour() ) self.headerPanel.Refresh() pass