diff options
author | Andrei Karas <akaras@inbox.ru> | 2014-02-15 20:31:52 +0300 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2014-02-15 20:31:52 +0300 |
commit | 29f929794c7519b049de0be3af635f05d7e83be6 (patch) | |
tree | 5627bfcb7f19a349f065c207476c871bc5c3aa40 /src/gui/viewport.cpp | |
parent | 41d545176ffad2fb33158ca3415d2a0a983fffdb (diff) | |
download | ManaVerse-29f929794c7519b049de0be3af635f05d7e83be6.tar.gz ManaVerse-29f929794c7519b049de0be3af635f05d7e83be6.tar.bz2 ManaVerse-29f929794c7519b049de0be3af635f05d7e83be6.tar.xz ManaVerse-29f929794c7519b049de0be3af635f05d7e83be6.zip |
move some methods from base/graphics into render/graphics.
Remove base/graphcs.
Diffstat (limited to 'src/gui/viewport.cpp')
-rw-r--r-- | src/gui/viewport.cpp | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/src/gui/viewport.cpp b/src/gui/viewport.cpp index 9982840de..2a91d1991 100644 --- a/src/gui/viewport.cpp +++ b/src/gui/viewport.cpp @@ -114,22 +114,20 @@ void Viewport::setMap(Map *const map) mMap = map; } -void Viewport::draw(gcn::Graphics *gcnGraphics) +void Viewport::draw(Graphics *graphics) { BLOCK_START("Viewport::draw 1") static int lastTick = tick_time; if (!mMap || !player_node) { - gcnGraphics->setColor(gcn::Color(64, 64, 64)); - gcnGraphics->fillRectangle( + graphics->setColor(gcn::Color(64, 64, 64)); + graphics->fillRectangle( gcn::Rectangle(0, 0, getWidth(), getHeight())); BLOCK_END("Viewport::draw 1") return; } - Graphics *const graphics = static_cast<Graphics* const>(gcnGraphics); - // Avoid freaking out when tick_time overflows if (tick_time < lastTick) lastTick = tick_time; @@ -260,7 +258,7 @@ void Viewport::draw(gcn::Graphics *gcnGraphics) miniStatusWindow->drawIcons(graphics); // Draw contained widgets - WindowContainer::draw(gcnGraphics); + WindowContainer::draw(graphics); BLOCK_END("Viewport::draw 1") } |