From 40f9688e729e2e2ee7f9b78835bf41b54df15409 Mon Sep 17 00:00:00 2001 From: Arrehn Date: Mon, 22 Aug 2011 16:23:37 -0400 Subject: [PATCH] FIRE-2266, part 2, DN fixes by Selo Jacobus --- indra/newview/llpanelprofileview.cpp | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/indra/newview/llpanelprofileview.cpp b/indra/newview/llpanelprofileview.cpp index c4666f1712..f3d73f3aa5 100644 --- a/indra/newview/llpanelprofileview.cpp +++ b/indra/newview/llpanelprofileview.cpp @@ -283,8 +283,15 @@ void LLPanelProfileView::onAvatarNameCache(const LLUUID& agent_id, getChild("user_name")->setValue( av_name.mUsername ); getChild("user_key")->setValue( agent_id.asString() ); getChild("copy_uri")->setEnabled( true ); + //[ADD: FIRE-2266: SJ] make sure username is always filled even when Displaynames are not enabled + std::string username = av_name.mUsername; + if (username.empty()) + { + username = LLCacheName::buildUsername(av_name.mDisplayName); + } + //[ADD: FIRE-2266: SJ] Adding link to webprofiles on profile which opens Web Profiles in browser - getChild("web_profile_text")->setValue( "https://my.secondlife.com/" + av_name.mUsername ); + getChild("web_profile_text")->setValue( "https://my.secondlife.com/" + username ); #if 0 getChild("user_name")->setValue( av_name.mDisplayName );