X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/6dfb13b1b7122da1700ca915ecf9d1047492c470..8f8c4b40456b5a4ef56a704c69570c7a1c86e714:/wxPython/wx/lib/colourselect.py diff --git a/wxPython/wx/lib/colourselect.py b/wxPython/wx/lib/colourselect.py index 6fb0bd7e77..8b196d6461 100644 --- a/wxPython/wx/lib/colourselect.py +++ b/wxPython/wx/lib/colourselect.py @@ -86,8 +86,10 @@ class ColourSelect(wx.BitmapButton): self.SetColour(colour) def SetColour(self, colour): - if type(colour) == type( () ): - colour = wxColour(*colour) + if type(colour) == tuple: + colour = wx.Colour(*colour) + if type(colour) == str: + colour = wx.NamedColour(colour) self.colour = colour bmp = self.MakeBitmap()