From cd438e160a1b3af0b96f8cd21e8cb1b240073021 Mon Sep 17 00:00:00 2001 From: Neil Date: Fri, 20 Apr 2018 08:27:32 +1000 Subject: Backport: Remove casts, drop default argument, use const. Backport of changeset 6708:6705d3f828c5. --- include/Platform.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'include') diff --git a/include/Platform.h b/include/Platform.h index 92180b354..773ae2439 100644 --- a/include/Platform.h +++ b/include/Platform.h @@ -217,15 +217,15 @@ public: return co; } - unsigned int GetRed() const { + unsigned char GetRed() const { return co & 0xff; } - unsigned int GetGreen() const { + unsigned char GetGreen() const { return (co >> 8) & 0xff; } - unsigned int GetBlue() const { + unsigned char GetBlue() const { return (co >> 16) & 0xff; } }; -- cgit v1.2.3