diff options
Diffstat (limited to 'src/gui/widgets/itemcontainer.cpp')
-rw-r--r-- | src/gui/widgets/itemcontainer.cpp | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/src/gui/widgets/itemcontainer.cpp b/src/gui/widgets/itemcontainer.cpp index a9df95a6..c8c98d0a 100644 --- a/src/gui/widgets/itemcontainer.cpp +++ b/src/gui/widgets/itemcontainer.cpp @@ -257,7 +257,7 @@ void ItemContainer::mousePressed(gcn::MouseEvent &event) { if(event.getClickCount() == 2) { - if (item->isEquipment()) + if (item->getInfo().getEquippable()) { if (item->isEquipped()) item->doEvent("doUnequip"); @@ -277,7 +277,7 @@ void ItemContainer::mousePressed(gcn::MouseEvent &event) { if(event.getClickCount() == 2) { - if (item->isEquipment()) + if (item->getInfo().getEquippable()) { if (item->isEquipped()) item->doEvent("doUnequip"); @@ -285,7 +285,9 @@ void ItemContainer::mousePressed(gcn::MouseEvent &event) item->doEvent("doEquip"); } else + { item->doEvent("doUse"); + } } else { @@ -294,7 +296,8 @@ void ItemContainer::mousePressed(gcn::MouseEvent &event) itemShortcut->setItemSelected(item->getId()); } - if (item->isEquipment()) + + if (item->getInfo().getEquippable()) outfitWindow->setItemSelected(item->getId()); } else |