From c7c6894dcede6778f311171f1128024b5ba97d84 Mon Sep 17 00:00:00 2001 From: Andrei Karas Date: Sat, 29 Jun 2013 23:24:52 +0300 Subject: fix working with protected items by automatic checks. --- src/gui/widgets/shoplistbox.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/gui/widgets/shoplistbox.cpp') diff --git a/src/gui/widgets/shoplistbox.cpp b/src/gui/widgets/shoplistbox.cpp index 827bb6755..6516b056f 100644 --- a/src/gui/widgets/shoplistbox.cpp +++ b/src/gui/widgets/shoplistbox.cpp @@ -108,8 +108,8 @@ void ShopListBox::draw(gcn::Graphics *gcnGraphics) gcn::Color* backgroundColor = &mBackgroundColor; ShopItem *const item = mShopItems->at(i); - if ((mShopItems && item && mPlayerMoney < item->getPrice() - && mPriceCheck) || PlayerInfo::isItemProtected(item->getId())) + if (item && ((mShopItems && mPlayerMoney < item->getPrice() + && mPriceCheck) || PlayerInfo::isItemProtected(item->getId()))) { if (i != mSelected) { -- cgit v1.2.3-60-g2f50