From 10a11861c685ab2250fb257666c5cda6dad0371c Mon Sep 17 00:00:00 2001 From: Andrei Karas Date: Sun, 25 Jan 2015 01:27:06 +0300 Subject: If cart window small hide filter field. --- src/gui/windows/inventorywindow.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) 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) -- cgit v1.2.3-60-g2f50