summaryrefslogtreecommitdiff
path: root/src/gui/windows/inventorywindow.cpp
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2015-01-25 01:27:06 +0300
committerAndrei Karas <akaras@inbox.ru>2015-01-25 01:27:06 +0300
commit10a11861c685ab2250fb257666c5cda6dad0371c (patch)
treefc05130aeaed7f304fc39232c897407422bc1e9c /src/gui/windows/inventorywindow.cpp
parentcc2c18c2b41e5409a0762b538568b41e9147c6e9 (diff)
downloadmanaverse-10a11861c685ab2250fb257666c5cda6dad0371c.tar.gz
manaverse-10a11861c685ab2250fb257666c5cda6dad0371c.tar.bz2
manaverse-10a11861c685ab2250fb257666c5cda6dad0371c.tar.xz
manaverse-10a11861c685ab2250fb257666c5cda6dad0371c.zip
If cart window small hide filter field.
Diffstat (limited to 'src/gui/windows/inventorywindow.cpp')
-rw-r--r--src/gui/windows/inventorywindow.cpp5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/gui/windows/inventorywindow.cpp b/src/gui/windows/inventorywindow.cpp
index 712ba7981..d99717c9b 100644
--- a/src/gui/windows/inventorywindow.cpp
+++ b/src/gui/windows/inventorywindow.cpp
@@ -874,7 +874,10 @@ void InventoryWindow::widgetResized(const Event &event)
{
Window::widgetResized(event);
- if (!isMainInventory())
+ if (!mInventory)
+ return;
+ const InventoryType::Type type = mInventory->getType();
+ if (type != InventoryType::INVENTORY && type != InventoryType::CART)
return;
if (getWidth() < 600)