diff options
author | mrwastl <mrwastl@users.sourceforge.net> | 2011-05-16 00:29:47 +0200 |
---|---|---|
committer | mrwastl <mrwastl@users.sourceforge.net> | 2011-05-16 00:29:47 +0200 |
commit | 38bea28bf1f88a45f2ada8b7f1c95cd5ea89a6bc (patch) | |
tree | ec49be8a0a733b32965abc0b8a90bda24bd9e64c /glcdgraphics/bitmap.h | |
parent | 4cd5223718a7f24ad31b2054263048e6af5dd1aa (diff) | |
download | graphlcd-base-38bea28bf1f88a45f2ada8b7f1c95cd5ea89a6bc.tar.gz graphlcd-base-38bea28bf1f88a45f2ada8b7f1c95cd5ea89a6bc.tar.bz2 |
oops, changes in cColor forgot in previous commit: minor clean up in class cColor, class member cColor::color is no longer public
Diffstat (limited to 'glcdgraphics/bitmap.h')
-rw-r--r-- | glcdgraphics/bitmap.h | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/glcdgraphics/bitmap.h b/glcdgraphics/bitmap.h index d87745d..7f17e51 100644 --- a/glcdgraphics/bitmap.h +++ b/glcdgraphics/bitmap.h @@ -45,9 +45,10 @@ enum eColor class cColor { -public: - uint32_t color; +protected: + uint32_t color; +public: cColor(uint32_t col) { color = col; } cColor(const cColor & col) { color = col.color; } @@ -62,13 +63,13 @@ public: static const uint32_t Transparent = 0x00FFFFFF; static const uint32_t ERRCOL = 0x00000000; - operator uint32_t(void) { return color; } - uint32_t GetColor (void) { return color; } void SetColor (uint32_t col) { color = col; } cColor Invert (void); + operator uint32_t(void) { return GetColor(); } + static cColor ParseColor (std::string col); static uint32_t AlignAlpha (uint32_t col) { return (col & 0xFF000000) ? col : (col | 0xFF000000); } }; |