diff options
author | Andrei Karas <akaras@inbox.ru> | 2015-02-15 19:39:27 +0300 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2015-02-15 19:39:27 +0300 |
commit | e6d25b2760a6bdb1b8c7305bdd3d72a607b58ff5 (patch) | |
tree | a9f641a60bcd1bc53e431ca1a341ca1ccda8972e /src/gui | |
parent | 3e622efc563e7359000c48eef265d6616026e52a (diff) | |
download | mv-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.cpp | 5 |
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) { |