diff --git a/include/SFML/Graphics/Color.hpp b/include/SFML/Graphics/Color.hpp index d32d59da..87a15982 100644 --- a/include/SFML/Graphics/Color.hpp +++ b/include/SFML/Graphics/Color.hpp @@ -75,7 +75,7 @@ public: /// \return Color represented as a 32-bit unsigned integer /// //////////////////////////////////////////////////////////// - Uint32 toInteger(); + Uint32 toInteger() const; //////////////////////////////////////////////////////////// // Static member data diff --git a/src/SFML/Graphics/Color.cpp b/src/SFML/Graphics/Color.cpp index 3fcec232..0bcd5024 100644 --- a/src/SFML/Graphics/Color.cpp +++ b/src/SFML/Graphics/Color.cpp @@ -79,7 +79,7 @@ a((color & 0x000000ff) >> 0 ) //////////////////////////////////////////////////////////// -Uint32 Color::toInteger() +Uint32 Color::toInteger() const { return (r << 24) | (g << 16) | (b << 8) | a; }