summaryrefslogtreecommitdiff
path: root/src/gui/windows
diff options
context:
space:
mode:
Diffstat (limited to 'src/gui/windows')
-rw-r--r--src/gui/windows/inventorywindow.cpp16
-rw-r--r--src/gui/windows/itemamountwindow.cpp1
-rw-r--r--src/gui/windows/shopwindow.cpp2
-rw-r--r--src/gui/windows/shopwindow.h1
4 files changed, 13 insertions, 7 deletions
diff --git a/src/gui/windows/inventorywindow.cpp b/src/gui/windows/inventorywindow.cpp
index 0a6c4c37f..bd6bdfc7f 100644
--- a/src/gui/windows/inventorywindow.cpp
+++ b/src/gui/windows/inventorywindow.cpp
@@ -120,6 +120,7 @@ InventoryWindow::InventoryWindow(Inventory *const inventory) :
case InventoryType::INVENTORY:
case InventoryType::TRADE:
case InventoryType::NPC:
+ case InventoryType::TYPE_END:
default:
mSortDropDown->setSelected(config.getIntValue(
"inventorySortOrder"));
@@ -207,7 +208,8 @@ InventoryWindow::InventoryWindow(Inventory *const inventory) :
mShopButton = new Button(this, _("S"), "shop", this);
// TRANSLATORS: inventory equipment button
mEquipmentButton = new Button(this, _("E"), "equipment", this);
- mWeightBar = new ProgressBar(this, 0.0F, 100, 0, Theme::PROG_WEIGHT,
+ mWeightBar = new ProgressBar(this, 0.0F, 100, 0,
+ Theme::PROG_WEIGHT,
"weightprogressbar.xml", "weightprogressbar_fill.xml");
mWeightBar->setColor(getThemeColor(Theme::WEIGHT_BAR),
getThemeColor(Theme::WEIGHT_BAR_OUTLINE));
@@ -247,7 +249,8 @@ InventoryWindow::InventoryWindow(Inventory *const inventory) :
// TRANSLATORS: storage button
mStoreButton = new Button(this, _("Store"), "store", this);
// TRANSLATORS: storage button
- mRetrieveButton = new Button(this, _("Retrieve"), "retrieve", this);
+ mRetrieveButton = new Button(this, _("Retrieve"),
+ "retrieve", this);
// TRANSLATORS: storage button
mInvCloseButton = new Button(this, _("Close"), "close", this);
@@ -269,11 +272,13 @@ InventoryWindow::InventoryWindow(Inventory *const inventory) :
// TRANSLATORS: storage button
mStoreButton = new Button(this, _("Store"), "store", this);
// TRANSLATORS: storage button
- mRetrieveButton = new Button(this, _("Retrieve"), "retrieve", this);
+ mRetrieveButton = new Button(this, _("Retrieve"),
+ "retrieve", this);
// TRANSLATORS: storage button
mInvCloseButton = new Button(this, _("Close"), "close", this);
- mWeightBar = new ProgressBar(this, 0.0F, 100, 0, Theme::PROG_WEIGHT,
+ mWeightBar = new ProgressBar(this, 0.0F, 100, 0,
+ Theme::PROG_WEIGHT,
"weightprogressbar.xml", "weightprogressbar_fill.xml");
mWeightBar->setColor(getThemeColor(Theme::WEIGHT_BAR),
getThemeColor(Theme::WEIGHT_BAR_OUTLINE));
@@ -295,6 +300,7 @@ InventoryWindow::InventoryWindow(Inventory *const inventory) :
default:
case InventoryType::TRADE:
case InventoryType::NPC:
+ case InventoryType::TYPE_END:
break;
};
@@ -348,6 +354,7 @@ void InventoryWindow::storeSortOrder() const
case InventoryType::INVENTORY:
case InventoryType::TRADE:
case InventoryType::NPC:
+ case InventoryType::TYPE_END:
default:
config.setValue("inventorySortOrder",
mSortDropDown->getSelected());
@@ -781,6 +788,7 @@ void InventoryWindow::close()
default:
case InventoryType::TRADE:
case InventoryType::NPC:
+ case InventoryType::TYPE_END:
break;
}
}
diff --git a/src/gui/windows/itemamountwindow.cpp b/src/gui/windows/itemamountwindow.cpp
index 5b714774c..fe081a799 100644
--- a/src/gui/windows/itemamountwindow.cpp
+++ b/src/gui/windows/itemamountwindow.cpp
@@ -22,7 +22,6 @@
#include "gui/windows/itemamountwindow.h"
-#include "inventory.h"
#include "item.h"
#include "being/playerinfo.h"
diff --git a/src/gui/windows/shopwindow.cpp b/src/gui/windows/shopwindow.cpp
index b04e60c59..9240b8e8c 100644
--- a/src/gui/windows/shopwindow.cpp
+++ b/src/gui/windows/shopwindow.cpp
@@ -37,7 +37,6 @@
#include "gui/widgets/button.h"
#include "gui/widgets/checkbox.h"
#include "gui/widgets/containerplacer.h"
-#include "gui/widgets/label.h"
#include "gui/widgets/layout.h"
#include "gui/widgets/layouttype.h"
#include "gui/widgets/scrollarea.h"
@@ -88,6 +87,7 @@ ShopWindow::ShopWindow() :
mTradeItem(nullptr),
mBuyShopItemList(new ShopListBox(this, mBuyShopItems, mBuyShopItems)),
mSellShopItemList(new ShopListBox(this, mSellShopItems, mSellShopItems)),
+ mCurrentShopItemList(nullptr),
mScrollArea(new ScrollArea(this, mBuyShopItemList,
getOptionBool("showbuybackground"), "shop_buy_background.xml")),
// TRANSLATORS: shop window label
diff --git a/src/gui/windows/shopwindow.h b/src/gui/windows/shopwindow.h
index 8ab765e3c..a3409bbe7 100644
--- a/src/gui/windows/shopwindow.h
+++ b/src/gui/windows/shopwindow.h
@@ -31,7 +31,6 @@
class Button;
class CheckBox;
class Item;
-class Label;
class ScrollArea;
class ShopItem;
class ShopItems;