From 1fcc02e803d83ae8415ff44f9696cb215f475daa Mon Sep 17 00:00:00 2001 From: Andrei Karas Date: Fri, 21 Feb 2014 13:30:39 +0300 Subject: fix signed shifts. --- src/gui/base/color.hpp | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) (limited to 'src/gui/base/color.hpp') diff --git a/src/gui/base/color.hpp b/src/gui/base/color.hpp index c32adb2e9..781b2cb60 100644 --- a/src/gui/base/color.hpp +++ b/src/gui/base/color.hpp @@ -93,7 +93,7 @@ namespace gcn * * @param color The color to initialise the object with. */ - explicit Color(const int color); + explicit Color(const unsigned int color); /** * Constructor. The default alpha value is 255. @@ -104,7 +104,10 @@ namespace gcn * @param a Alpha, used for transparency. A value of 0 means * totaly transparent, 255 is totaly opaque. */ - Color(const int r, const int g, const int b, const int a = 255); + Color(const unsigned int r, + const unsigned int g, + const unsigned int b, + const unsigned int a = 255); /** * Adds the RGB values of two colors together. The values will be @@ -169,23 +172,23 @@ namespace gcn /** * Holds the red color component (range 0-255). */ - int r; + unsigned int r; /** * Holds the green color component (range 0-255). */ - int g; + unsigned int g; /** * Holds the blue color component (range 0-255). */ - int b; + unsigned int b; /** * Holds the alpha color component. A value of 0 means totally * transparent while a value of 255 is considered opaque. */ - int a; + unsigned int a; }; } // namespace gcn -- cgit v1.2.3-60-g2f50