diff options
author | Andrei Karas <akaras@inbox.ru> | 2011-01-14 01:39:58 +0200 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2011-01-14 01:39:58 +0200 |
commit | 175027e204d936b2c775fe587e7d3f14e71e1233 (patch) | |
tree | ad0e56e5da67ef47aa94ff0bc9f4757afc9b57d7 /src/gui/inventorywindow.cpp | |
parent | 0b3368c1675e774954068de6427d0fad282a9293 (diff) | |
download | mv-175027e204d936b2c775fe587e7d3f14e71e1233.tar.gz mv-175027e204d936b2c775fe587e7d3f14e71e1233.tar.bz2 mv-175027e204d936b2c775fe587e7d3f14e71e1233.tar.xz mv-175027e204d936b2c775fe587e7d3f14e71e1233.zip |
Add unification for inventory/storage/cart name.
Diffstat (limited to 'src/gui/inventorywindow.cpp')
-rw-r--r-- | src/gui/inventorywindow.cpp | 16 |
1 files changed, 12 insertions, 4 deletions
diff --git a/src/gui/inventorywindow.cpp b/src/gui/inventorywindow.cpp index 978bfcecf..f63e01d6a 100644 --- a/src/gui/inventorywindow.cpp +++ b/src/gui/inventorywindow.cpp @@ -61,15 +61,23 @@ InventoryWindow::WindowList InventoryWindow::instances; InventoryWindow::InventoryWindow(Inventory *inventory): - Window(inventory ? (inventory->isMainInventory() - ? _("Inventory") : _("Storage")) : _("Inventory")), + Window(), mInventory(inventory), mDropButton(0), mSplit(false) { - listen(CHANNEL_ATTRIBUTES); + if (inventory) + { + setCaption(gettext(inventory->getName().c_str())); + setWindowName(inventory->getName()); + } + else + { + setCaption(_("Inventory")); + setWindowName("Inventory"); + } - setWindowName(isMainInventory() ? "Inventory" : "Storage"); + listen(CHANNEL_ATTRIBUTES); if (setupWindow) setupWindow->registerWindowForReset(this); |