summaryrefslogtreecommitdiff
path: root/src/gui/widgets
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2012-08-07 22:42:41 +0300
committerAndrei Karas <akaras@inbox.ru>2012-08-07 22:42:41 +0300
commitd27fa21ab9363eb22f5077e085c54332da05899f (patch)
tree2e13bfabf6a5292ca6cfe31944a739a722dcd066 /src/gui/widgets
parentf09e2fdbbf85c6f4c02c9f2fc294b867a94fcacd (diff)
downloadmv-d27fa21ab9363eb22f5077e085c54332da05899f.tar.gz
mv-d27fa21ab9363eb22f5077e085c54332da05899f.tar.bz2
mv-d27fa21ab9363eb22f5077e085c54332da05899f.tar.xz
mv-d27fa21ab9363eb22f5077e085c54332da05899f.zip
Fix background draw in buy/sell dialogs.
Diffstat (limited to 'src/gui/widgets')
-rw-r--r--src/gui/widgets/shoplistbox.cpp9
1 files changed, 5 insertions, 4 deletions
diff --git a/src/gui/widgets/shoplistbox.cpp b/src/gui/widgets/shoplistbox.cpp
index 6171e9f03..c7a3bdb1e 100644
--- a/src/gui/widgets/shoplistbox.cpp
+++ b/src/gui/widgets/shoplistbox.cpp
@@ -95,12 +95,14 @@ void ShopListBox::draw(gcn::Graphics *gcnGraphics)
Graphics *graphics = static_cast<Graphics*>(gcnGraphics);
graphics->setFont(getFont());
+ graphics->setColor(getForegroundColor());
// Draw the list elements
for (int i = 0, y = 0;
i < mListModel->getNumberOfElements();
++i, y += mRowHeight)
{
+/*
gcn::Color temp;
gcn::Color* backgroundColor = &mBackgroundColor;
mBackgroundColor.a = alpha;
@@ -128,9 +130,9 @@ void ShopListBox::draw(gcn::Graphics *gcnGraphics)
backgroundColor = &mHighlightColor;
}
- graphics->setColor(*backgroundColor);
- graphics->fillRectangle(gcn::Rectangle(0, y, getWidth(), mRowHeight));
-
+// graphics->setColor(*backgroundColor);
+// graphics->fillRectangle(gcn::Rectangle(0, y, getWidth(), mRowHeight));
+*/
if (mShopItems)
{
Image *icon = mShopItems->at(i)->getImage();
@@ -140,7 +142,6 @@ void ShopListBox::draw(gcn::Graphics *gcnGraphics)
graphics->drawImage(icon, 1, y);
}
}
- graphics->setColor(getForegroundColor());
graphics->drawText(mListModel->getElementAt(i), ITEM_ICON_SIZE + 5,
y + (ITEM_ICON_SIZE - getFont()->getHeight()) / 2);
}