wxColour -> NSColor conversion.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@62530 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -60,6 +60,7 @@ public:
|
|||||||
#endif
|
#endif
|
||||||
#if wxOSX_USE_COCOA
|
#if wxOSX_USE_COCOA
|
||||||
wxColour(WX_NSColor color);
|
wxColour(WX_NSColor color);
|
||||||
|
WX_NSColor OSXGetNSColor();
|
||||||
#endif
|
#endif
|
||||||
wxColour& operator=(CGColorRef col);
|
wxColour& operator=(CGColorRef col);
|
||||||
wxColour& operator=(const wxColour& col);
|
wxColour& operator=(const wxColour& col);
|
||||||
|
@@ -33,4 +33,9 @@ wxColour::wxColour(WX_NSColor col)
|
|||||||
}
|
}
|
||||||
InitFromComponents(const_cast<const CGFloat*>(components), noComp);
|
InitFromComponents(const_cast<const CGFloat*>(components), noComp);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
WX_NSColor wxColour::OSXGetNSColor()
|
||||||
|
{
|
||||||
|
return [NSColor colorWithDeviceRed:m_red / 255.0 green:m_green / 255.0 blue:m_blue / 255.0 alpha:m_alpha / 255.0];
|
||||||
|
}
|
||||||
#endif
|
#endif
|
Reference in New Issue
Block a user