diff options
author | James Cook <james@lindenlab.com> | 2010-03-13 22:00:40 -0800 |
---|---|---|
committer | James Cook <james@lindenlab.com> | 2010-03-13 22:00:40 -0800 |
commit | 10fc6ee4a012fa7232868261d6e11a76652c3cca (patch) | |
tree | 79ed5f03e981a9db9c05427134df0cdfc171b3fc | |
parent | f0d3ea53cd570eeca88df1d0c7d8a73c0877789b (diff) |
Hack to use display names for text chat
-rw-r--r-- | indra/newview/llviewermessage.cpp | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/indra/newview/llviewermessage.cpp b/indra/newview/llviewermessage.cpp index 6a8832b64d..a1ff0f3747 100644 --- a/indra/newview/llviewermessage.cpp +++ b/indra/newview/llviewermessage.cpp @@ -2627,7 +2627,18 @@ void process_chat_from_simulator(LLMessageSystem *msg, void **user_data) // IDEVO Correct for new-style "Resident" names if (chat.mSourceType == CHAT_SOURCE_AGENT) { - chat.mFromName = LLCacheName::cleanFullName(from_name); + // JAMESDEBUG - I don't know if it's OK to change this here, if + // anything downstream does lookups by name, for instance + LLAvatarName av_name; + if (LLAvatarNameCache::useDisplayNames() + && LLAvatarNameCache::get(from_id, &av_name)) + { + chat.mFromName = av_name.mDisplayName; + } + else + { + chat.mFromName = LLCacheName::cleanFullName(from_name); + } } else { |