summaryrefslogtreecommitdiff
path: root/src/gui/itemcontainer.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/gui/itemcontainer.cpp')
-rw-r--r--src/gui/itemcontainer.cpp9
1 files changed, 3 insertions, 6 deletions
diff --git a/src/gui/itemcontainer.cpp b/src/gui/itemcontainer.cpp
index a176f226..0e5bcce9 100644
--- a/src/gui/itemcontainer.cpp
+++ b/src/gui/itemcontainer.cpp
@@ -105,16 +105,13 @@ ItemContainer::draw(gcn::Graphics *graphics)
// Draw selection image below selected item
if (mSelectedItem == item)
{
- dynamic_cast<Graphics*>(graphics)->drawImage(
- mSelImg, itemX, itemY);
+ static_cast<Graphics*>(graphics)->drawImage(mSelImg, itemX, itemY);
}
// Draw item icon
- Image* image;
- if ((image = item->getInfo().getImage()) != NULL)
+ if (Image *image = item->getInfo().getImage())
{
- dynamic_cast<Graphics*>(graphics)->drawImage(
- image, itemX, itemY);
+ static_cast<Graphics*>(graphics)->drawImage(image, itemX, itemY);
}
// Draw item caption