summaryrefslogtreecommitdiff
path: root/indra/newview/llinventorymodel.cpp
diff options
context:
space:
mode:
authorTofu Linden <tofu.linden@lindenlab.com>2010-06-08 16:48:47 +0100
committerTofu Linden <tofu.linden@lindenlab.com>2010-06-08 16:48:47 +0100
commit9d0a5c6e914f07c0ce3653a8196cb12014405c61 (patch)
tree32cb5f6c4c3d96ea4af6d98b0442ab1c40bd3341 /indra/newview/llinventorymodel.cpp
parent2f3019d670e8310f00fe4284a7fc09ee59c0f9bf (diff)
parentd17b616b1c94c136254de0bee039cdc87979b44e (diff)
merge from PE's viewer-release
Diffstat (limited to 'indra/newview/llinventorymodel.cpp')
-rw-r--r--indra/newview/llinventorymodel.cpp16
1 files changed, 14 insertions, 2 deletions
diff --git a/indra/newview/llinventorymodel.cpp b/indra/newview/llinventorymodel.cpp
index 6fc5804a48..15760bf155 100644
--- a/indra/newview/llinventorymodel.cpp
+++ b/indra/newview/llinventorymodel.cpp
@@ -721,8 +721,20 @@ U32 LLInventoryModel::updateItem(const LLViewerInventoryItem* item)
// Valid UUID; set the item UUID and rename it
new_item->setCreator(id);
std::string avatar_name;
- // Fetch the currect name
- gCacheName->get(id, FALSE, boost::bind(&LLViewerInventoryItem::onCallingCardNameLookup, new_item.get(), _1, _2, _3));
+
+ if (gCacheName->getFullName(id, avatar_name))
+ {
+ new_item->rename(avatar_name);
+ mask |= LLInventoryObserver::LABEL;
+ }
+ else
+ {
+ // Fetch the current name
+ gCacheName->get(id, FALSE,
+ boost::bind(&LLViewerInventoryItem::onCallingCardNameLookup, new_item.get(),
+ _1, _2, _3));
+ }
+
}
}
else if (new_item->getType() == LLAssetType::AT_GESTURE)