diff options
author | Philipp Sehmisch <crush@themanaworld.org> | 2009-02-10 16:10:58 +0100 |
---|---|---|
committer | Ira Rice <irarice@gmail.com> | 2009-02-10 12:36:27 -0700 |
commit | c674c0310d932f9cb76340a50dbcbe901daade12 (patch) | |
tree | 0d0326043d9644bd2fb576e5703d84449b2812f4 /src/gui | |
parent | 243cd9b123069decdcbefa05d04517492efbc3ee (diff) | |
download | mana-c674c0310d932f9cb76340a50dbcbe901daade12.tar.gz mana-c674c0310d932f9cb76340a50dbcbe901daade12.tar.bz2 mana-c674c0310d932f9cb76340a50dbcbe901daade12.tar.xz mana-c674c0310d932f9cb76340a50dbcbe901daade12.zip |
Removed decimals from color sliders
Diffstat (limited to 'src/gui')
-rw-r--r-- | src/gui/setup_colours.cpp | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/src/gui/setup_colours.cpp b/src/gui/setup_colours.cpp index 82499560..f986fded 100644 --- a/src/gui/setup_colours.cpp +++ b/src/gui/setup_colours.cpp @@ -20,6 +20,7 @@ */ #include <string> +#include <cmath> #include <guichan/listmodel.hpp> #include <guichan/widgets/label.hpp> @@ -171,21 +172,21 @@ void Setup_Colours::action(const gcn::ActionEvent &event) if (event.getId() == "slider_red") { - mRedText->setText(toString(mRedSlider->getValue())); + mRedText->setText(toString(std::floor(mRedSlider->getValue()))); updateColour(); return; } if (event.getId() == "slider_green") { - mGreenText->setText(toString(mGreenSlider->getValue())); + mGreenText->setText(toString(std::floor(mGreenSlider->getValue()))); updateColour(); return; } if (event.getId() == "slider_blue") { - mBlueText->setText(toString(mBlueSlider->getValue())); + mBlueText->setText(toString(std::floor(mBlueSlider->getValue()))); updateColour(); return; } |