diff options
Diffstat (limited to 'src/gui')
-rw-r--r-- | src/gui/widgets/itemcontainer.cpp | 5 | ||||
-rw-r--r-- | src/gui/windows/npcdialog.cpp | 2 |
2 files changed, 4 insertions, 3 deletions
diff --git a/src/gui/widgets/itemcontainer.cpp b/src/gui/widgets/itemcontainer.cpp index 8fc8b09e4..fec14b814 100644 --- a/src/gui/widgets/itemcontainer.cpp +++ b/src/gui/widgets/itemcontainer.cpp @@ -631,8 +631,9 @@ void ItemContainer::mouseReleased(MouseEvent &event) inventory = PlayerInfo::getInventory(); if (inventory) { - mInventory->addVirtualItem(inventory->getItem( - dragDrop.getTag())); + mInventory->addVirtualItem( + inventory->getItem(dragDrop.getTag()), + getSlotIndex(event.getX(), event.getY())); } return; } diff --git a/src/gui/windows/npcdialog.cpp b/src/gui/windows/npcdialog.cpp index 5cc538e34..f601c6405 100644 --- a/src/gui/windows/npcdialog.cpp +++ b/src/gui/windows/npcdialog.cpp @@ -542,7 +542,7 @@ void NpcDialog::action(const ActionEvent &event) else if (eventId == "add") { if (inventoryWindow) - mInventory->addVirtualItem(inventoryWindow->getSelectedItem()); + mInventory->addVirtualItem(inventoryWindow->getSelectedItem(), 0); } else if (eventId.find("skin_") == 0) { |