summaryrefslogtreecommitdiff
path: root/src/gui
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2015-02-15 19:39:27 +0300
committerAndrei Karas <akaras@inbox.ru>2015-02-15 19:39:27 +0300
commite6d25b2760a6bdb1b8c7305bdd3d72a607b58ff5 (patch)
treea9f641a60bcd1bc53e431ca1a341ca1ccda8972e /src/gui
parent3e622efc563e7359000c48eef265d6616026e52a (diff)
downloadmv-e6d25b2760a6bdb1b8c7305bdd3d72a607b58ff5.tar.gz
mv-e6d25b2760a6bdb1b8c7305bdd3d72a607b58ff5.tar.bz2
mv-e6d25b2760a6bdb1b8c7305bdd3d72a607b58ff5.tar.xz
mv-e6d25b2760a6bdb1b8c7305bdd3d72a607b58ff5.zip
fix enable/disable add/remove buttons in shop window in buy dialog.
Diffstat (limited to 'src/gui')
-rw-r--r--src/gui/windows/shopwindow.cpp5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/gui/windows/shopwindow.cpp b/src/gui/windows/shopwindow.cpp
index 67c076912..8f858b0fe 100644
--- a/src/gui/windows/shopwindow.cpp
+++ b/src/gui/windows/shopwindow.cpp
@@ -417,8 +417,9 @@ void ShopWindow::updateButtonsAndLabels()
const bool sellNotEmpty = mSellShopItems->getNumberOfElements() > 0;
if (isBuySelected)
{
- allowAdd = !mEnableVending;
- allowDel = mBuyShopItemList->getSelected() != -1
+ allowAdd = !mEnableBuyingStore;
+ allowDel = !mEnableBuyingStore
+ && mBuyShopItemList->getSelected() != -1
&& mBuyShopItems->getNumberOfElements() > 0;
if (mPublishButton)
{