From 62651de51245ed7377bfdbf3212ac99321c3547f Mon Sep 17 00:00:00 2001 From: Andrei Karas Date: Fri, 15 Apr 2011 00:10:31 +0300 Subject: Show id on unknown items. --- src/gui/itempopup.cpp | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) (limited to 'src/gui/itempopup.cpp') diff --git a/src/gui/itempopup.cpp b/src/gui/itempopup.cpp index e09d0ce0a..5e50e2e55 100644 --- a/src/gui/itempopup.cpp +++ b/src/gui/itempopup.cpp @@ -100,7 +100,7 @@ void ItemPopup::setItem(const Item *item, bool showImage) return; const ItemInfo &ii = item->getInfo(); - setItem(ii, item->getColor(), showImage); + setItem(ii, item->getColor(), showImage, item->getId()); if (item->getRefine() > 0) { mLastName = ii.getName(); @@ -123,11 +123,14 @@ void ItemPopup::setItem(const Item *item, bool showImage) } void ItemPopup::setItem(const ItemInfo &item, unsigned char color, - bool showImage) + bool showImage, int id) { if (!mIcon || (item.getName() == mLastName && color == mLastColor)) return; + if (id == -1) + id = item.getId(); + int space = 0; Image *oldImage = mIcon->getImage(); @@ -166,13 +169,13 @@ void ItemPopup::setItem(const ItemInfo &item, unsigned char color, if (serverVersion > 0) { mItemName->setCaption(item.getName(color) + _(", ") - + toString(item.getId())); + + toString(id)); mItemDesc->setTextWrapped(item.getDescription(color), 196); } else { mItemName->setCaption(item.getName() + _(", ") - + toString(item.getId())); + + toString(id)); mItemDesc->setTextWrapped(item.getDescription(), 196); } -- cgit v1.2.3-60-g2f50