X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/8f884a0dccd6b642f35c441ac9bfc87a6d5b4d35..616c0d1f3ac084bb92f0a75dc48812e8647f1b22:/include/wx/cocoa/colour.h?ds=sidebyside diff --git a/include/wx/cocoa/colour.h b/include/wx/cocoa/colour.h index f0d7af4271..3209d94f0c 100644 --- a/include/wx/cocoa/colour.h +++ b/include/wx/cocoa/colour.h @@ -19,30 +19,16 @@ // wxColour // ======================================================================== -class WXDLLEXPORT wxColour : public wxColourBase +class WXDLLIMPEXP_CORE wxColour : public wxColourBase { public: // constructors // ------------ - - // default - wxColour() { Init(); } - - // the other standard ones: notice that we can't use - // DEFINE_STD_WXCOLOUR_CONSTRUCTORS here because we need to call Init() to - // initialize m_cocoaNSColor and the macro doesn't do it - wxColour( ChannelType red, ChannelType green, ChannelType blue, - ChannelType alpha = wxALPHA_OPAQUE ) - { Init(); Set(red, green, blue, alpha); } - wxColour(unsigned long colRGB) { Init(); Set(colRGB); } - wxColour(const wxString& colourName) { Init(); Set(colourName); } - wxColour(const char *colourName) { Init(); Set(colourName); } - wxColour(const wchar_t *colourName) { Init(); Set(colourName); } + DEFINE_STD_WXCOLOUR_CONSTRUCTORS // initialization using existing NSColor wxColour( WX_NSColor aColor ); - // copy ctors and assignment operators wxColour( const wxColour& col ); wxColour& operator = ( const wxColour& col ); @@ -52,6 +38,7 @@ public: // accessors virtual bool IsOk() const { return m_cocoaNSColor; } WX_NSColor GetNSColor() { return m_cocoaNSColor; } + WX_NSColor GetNSColor() const { return m_cocoaNSColor; } unsigned char Red() const { return m_red; } unsigned char Green() const { return m_green; }