summaryrefslogtreecommitdiff
path: root/src/gui/widgets/dropshortcutcontainer.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/gui/widgets/dropshortcutcontainer.cpp')
-rw-r--r--src/gui/widgets/dropshortcutcontainer.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/gui/widgets/dropshortcutcontainer.cpp b/src/gui/widgets/dropshortcutcontainer.cpp
index 9fb20b041..bc6b3d878 100644
--- a/src/gui/widgets/dropshortcutcontainer.cpp
+++ b/src/gui/widgets/dropshortcutcontainer.cpp
@@ -222,7 +222,8 @@ void DropShortcutContainer::mousePressed(gcn::MouseEvent &event)
if (event.getButton() == gcn::MouseEvent::LEFT)
{
// Stores the selected item if theirs one.
- if (dropShortcut->isItemSelected() && inventoryWindow->isVisible())
+ if (dropShortcut->isItemSelected()
+ && inventoryWindow->isWindowVisible())
{
dropShortcut->setItem(index);
dropShortcut->setItemSelected(-1);