From ffaadb3ddad5b8577786f7176e4415db68f115f0 Mon Sep 17 00:00:00 2001 From: Andrei Karas Date: Tue, 27 Jan 2015 23:15:33 +0300 Subject: Redesign shop window into tabbed window. --- src/gui/windows/shopwindow.h | 22 ++++++++++------------ 1 file changed, 10 insertions(+), 12 deletions(-) (limited to 'src/gui/windows/shopwindow.h') diff --git a/src/gui/windows/shopwindow.h b/src/gui/windows/shopwindow.h index c8ad56294..8ab765e3c 100644 --- a/src/gui/windows/shopwindow.h +++ b/src/gui/windows/shopwindow.h @@ -36,6 +36,7 @@ class ScrollArea; class ShopItem; class ShopItems; class ShopListBox; +class TabStrip; /** * The buy dialog. @@ -140,6 +141,8 @@ class ShopWindow final : public Window, private: void startTrade(); + void updateSelection(); + typedef std::list DialogList; static DialogList instances; @@ -151,19 +154,13 @@ class ShopWindow final : public Window, ShopListBox *mBuyShopItemList; ShopListBox *mSellShopItemList; - ScrollArea *mBuyScrollArea; - ScrollArea *mSellScrollArea; - Label *mBuyLabel; - Label *mSellLabel; - Button *mBuyAddButton; - Button *mBuyDeleteButton; - Button *mBuyAnnounceButton; - Button *mBuyAuctionButton; - Button *mSellAddButton; - Button *mSellDeleteButton; - Button *mSellAnnounceButton; - Button *mSellAuctionButton; + ShopListBox *mCurrentShopItemList; + ScrollArea *mScrollArea; + Button *mAddButton; + Button *mDeleteButton; + Button *mAnnounceButton; CheckBox *mAnnounceLinks; + TabStrip *mTabs; std::string mAcceptPlayer; std::string mTradeNick; int mSelectedItem; @@ -173,6 +170,7 @@ class ShopWindow final : public Window, int mRandCounter; int mTradeMoney; int mAnnounceCounter[2]; + bool isBuySelected; }; extern ShopWindow *shopWindow; -- cgit v1.2.3-70-g09d2