summaryrefslogtreecommitdiff
path: root/src/gui/shoplistbox.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/gui/shoplistbox.cpp')
-rw-r--r--src/gui/shoplistbox.cpp20
1 files changed, 2 insertions, 18 deletions
diff --git a/src/gui/shoplistbox.cpp b/src/gui/shoplistbox.cpp
index 0e2ea6d3..ae787ab7 100644
--- a/src/gui/shoplistbox.cpp
+++ b/src/gui/shoplistbox.cpp
@@ -129,24 +129,8 @@ void ShopListBox::mousePressed(gcn::MouseEvent &event)
{
if (event.getButton() == gcn::MouseEvent::LEFT)
{
- bool enoughMoney = false;
- int y = event.getY();
-
- if (mShopItems && mPriceCheck)
- {
- if (mPlayerMoney >= mShopItems->at(y / mRowHeight).price)
- enoughMoney = true;
- }
- else // Old Behaviour
- {
- enoughMoney = true;
- }
-
- if (enoughMoney)
- {
- setSelected(y / mRowHeight);
- generateAction();
- }
+ setSelected(event.getY() / mRowHeight);
+ generateAction();
}
}