summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/gui/minimap.cpp7
-rw-r--r--src/gui/sell.cpp5
2 files changed, 9 insertions, 3 deletions
diff --git a/src/gui/minimap.cpp b/src/gui/minimap.cpp
index ca6f4fd7..5f768609 100644
--- a/src/gui/minimap.cpp
+++ b/src/gui/minimap.cpp
@@ -77,9 +77,10 @@ void Minimap::draw(gcn::Graphics *graphics)
{
Window::draw(graphics);
- if (mMapImage != NULL)
+ if (mMapImage)
{
- static_cast<Graphics*>(graphics)->drawImage(mMapImage, getPadding(), getTitleBarHeight());
+ static_cast<Graphics*>(graphics)->drawImage(
+ mMapImage, getPadding(), getTitleBarHeight());
}
Beings &beings = beingManager->getAll();
@@ -110,7 +111,7 @@ void Minimap::draw(gcn::Graphics *graphics)
break;
default:
- break;
+ continue;
}
const int offset = (dotSize - 1) / 2;
diff --git a/src/gui/sell.cpp b/src/gui/sell.cpp
index e101ad39..37626155 100644
--- a/src/gui/sell.cpp
+++ b/src/gui/sell.cpp
@@ -171,6 +171,11 @@ void SellDialog::action(const gcn::ActionEvent &event)
mShopItemList->setSelected(-1);
mShopItems->getShop()->erase(
mShopItems->getShop()->begin() + selectedItem);
+
+ gcn::Rectangle scroll;
+ scroll.y = mShopItemList->getRowHeight() * (selectedItem + 1);
+ scroll.height = mShopItemList->getRowHeight();
+ mShopItemList->showPart(scroll);
}
else
{