diff options
author | James Cook <james@lindenlab.com> | 2010-02-08 14:55:30 -0800 |
---|---|---|
committer | James Cook <james@lindenlab.com> | 2010-02-08 14:55:30 -0800 |
commit | 42176145c9e81dd99b65f88152df50a7b3ccf834 (patch) | |
tree | bfca296db7fd5bbe793652dfecc12ba396dd2c25 /indra/newview/llviewermenu.cpp | |
parent | 33e613531f929b5bce04c11a355085fe5ea92997 (diff) |
Converted names build from avatar object LLNameValue pairs to SLID
Added temporary getDisplayName() to LLCacheName
Moved temporary placeholder display names into LLCacheName
Eliminated rarely used LLAgentUI::buildName in favor of buildFullName
Standardized buildFullName capitalization
Diffstat (limited to 'indra/newview/llviewermenu.cpp')
-rw-r--r-- | indra/newview/llviewermenu.cpp | 19 |
1 files changed, 7 insertions, 12 deletions
diff --git a/indra/newview/llviewermenu.cpp b/indra/newview/llviewermenu.cpp index 6eb607fc6c..6f6932367f 100644 --- a/indra/newview/llviewermenu.cpp +++ b/indra/newview/llviewermenu.cpp @@ -2758,9 +2758,8 @@ class LLObjectMute : public view_listener_t LLNameValue *lastname = avatar->getNVPair("LastName"); if (firstname && lastname) { - name = firstname->getString(); - name += " "; - name += lastname->getString(); + name = LLCacheName::buildFullName( + firstname->getString(), lastname->getString()); } type = LLMute::AGENT; @@ -3517,21 +3516,17 @@ void request_friendship(const LLUUID& dest_id) LLViewerObject* dest = gObjectList.findObject(dest_id); if(dest && dest->isAvatar()) { - std::string fullname; - LLSD args; + std::string full_name; LLNameValue* nvfirst = dest->getNVPair("FirstName"); LLNameValue* nvlast = dest->getNVPair("LastName"); if(nvfirst && nvlast) { - args["FIRST"] = nvfirst->getString(); - args["LAST"] = nvlast->getString(); - fullname = nvfirst->getString(); - fullname += " "; - fullname += nvlast->getString(); + full_name = LLCacheName::buildFullName( + nvfirst->getString(), nvlast->getString()); } - if (!fullname.empty()) + if (!full_name.empty()) { - LLAvatarActions::requestFriendshipDialog(dest_id, fullname); + LLAvatarActions::requestFriendshipDialog(dest_id, full_name); } else { |