Get rid of unnecessary wxColour::InitFromComponents() in wxOSX
This method was confusing and dangerous as it didn't actually initialize the wxColour object because it didn't set its m_cgColour and so attempting to use wxColour "initialized" using this method resulted in a crash whenever its GetPixel(), GetCGColor() or CreateCGColor() methods were called. Just merge this function with InitCGColorRef() which is the only remaining place where it's used after rewriting wxColour(NSColor) ctor.
This commit is contained in:
@@ -72,7 +72,7 @@ protected :
|
||||
void InitRGBColor( const RGBColor& col );
|
||||
#endif
|
||||
void InitCGColorRef( CGColorRef col );
|
||||
void InitFromComponents(const CGFloat* components, size_t numComponents );
|
||||
|
||||
private:
|
||||
wxCFRef<CGColorRef> m_cgColour;
|
||||
|
||||
|
Reference in New Issue
Block a user