diff options
author | Andrei Karas <akaras@inbox.ru> | 2013-12-14 16:59:21 +0300 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2013-12-14 16:59:21 +0300 |
commit | d9a77eb8ac5d507665cbf8b20f5d8187148ebfd1 (patch) | |
tree | db2f8a25d466ce6aa5ca1747216156f7869a06d1 /src/gui/widgets/slider.cpp | |
parent | 2851324a6847efa7ea6f556941b369e9e304dc23 (diff) | |
download | plus-d9a77eb8ac5d507665cbf8b20f5d8187148ebfd1.tar.gz plus-d9a77eb8ac5d507665cbf8b20f5d8187148ebfd1.tar.bz2 plus-d9a77eb8ac5d507665cbf8b20f5d8187148ebfd1.tar.xz plus-d9a77eb8ac5d507665cbf8b20f5d8187148ebfd1.zip |
Improve a bit separate images drawing.
Diffstat (limited to 'src/gui/widgets/slider.cpp')
-rw-r--r-- | src/gui/widgets/slider.cpp | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/src/gui/widgets/slider.cpp b/src/gui/widgets/slider.cpp index 20fc6b21b..47d4e2215 100644 --- a/src/gui/widgets/slider.cpp +++ b/src/gui/widgets/slider.cpp @@ -204,7 +204,7 @@ void Slider::draw(gcn::Graphics *graphics) { if (!mHasMouse) { - g->drawImage(buttons[0].grid[HSTART], x, y); + DRAW_IMAGE(g, buttons[0].grid[HSTART], x, y); const int width = buttons[0].grid[HSTART]->getWidth(); w -= width + buttons[0].grid[HEND]->getWidth(); x += width; @@ -216,18 +216,18 @@ void Slider::draw(gcn::Graphics *graphics) } x += w; - g->drawImage(buttons[0].grid[HEND], x, y); + DRAW_IMAGE(g, buttons[0].grid[HEND], x, y); const Image *const img = buttons[0].grid[HGRIP]; if (img) { - g->drawImage(img, getMarkerPosition(), + DRAW_IMAGE(g, img, getMarkerPosition(), (mDimension.height - img->getHeight()) / 2); } } else { - g->drawImage(buttons[1].grid[HSTART], x, y); + DRAW_IMAGE(g, buttons[1].grid[HSTART], x, y); const int width = buttons[1].grid[HSTART]->getWidth(); w -= width; @@ -243,12 +243,12 @@ void Slider::draw(gcn::Graphics *graphics) x += w; if (buttons[1].grid[HEND]) - g->drawImage(buttons[1].grid[HEND], x, y); + DRAW_IMAGE(g, buttons[1].grid[HEND], x, y); const Image *const img = buttons[1].grid[HGRIP]; if (img) { - g->drawImage(img, getMarkerPosition(), + DRAW_IMAGE(g, img, getMarkerPosition(), (mDimension.height - img->getHeight()) / 2); } } |