diff options
-rw-r--r-- | indra/newview/llpanelprofileview.cpp | 25 | ||||
-rw-r--r-- | indra/newview/llpanelprofileview.h | 10 |
2 files changed, 14 insertions, 21 deletions
diff --git a/indra/newview/llpanelprofileview.cpp b/indra/newview/llpanelprofileview.cpp index 5688c6960b..526db2a192 100644 --- a/indra/newview/llpanelprofileview.cpp +++ b/indra/newview/llpanelprofileview.cpp @@ -108,8 +108,10 @@ void LLPanelProfileView::onOpen(const LLSD& key) } // Update the avatar name. - gCacheName->get(getAvatarId(), false, - boost::bind(&LLPanelProfileView::onNameCache, this, _1, _2, _3)); +// gCacheName->get(getAvatarId(), false, +// boost::bind(&LLPanelProfileView::onNameCache, this, _1, _2, _3)); + LLAvatarNameCache::get(getAvatarId(), + boost::bind(&LLPanelProfileView::onAvatarNameCache, this, _1, _2)); updateOnlineStatus(); @@ -199,22 +201,11 @@ void LLPanelProfileView::processOnlineStatus(bool online) mStatusText->setValue(status); } -void LLPanelProfileView::onNameCache(const LLUUID& id, const std::string& full_name, bool is_group) +void LLPanelProfileView::onAvatarNameCache(const LLUUID& agent_id, + const LLAvatarName& av_name) { - llassert(getAvatarId() == id); - // IDEVO - LLAvatarName av_name; - if (LLAvatarNameCache::useDisplayNames() - && LLAvatarNameCache::get(id, &av_name)) - { - getChild<LLUICtrl>("user_name")->setValue( av_name.mDisplayName ); - getChild<LLUICtrl>("user_slid")->setValue( av_name.mSLID ); - } - else - { - getChild<LLUICtrl>("user_name")->setValue(full_name); - getChild<LLUICtrl>("user_slid")->setValue(""); - } + getChild<LLUICtrl>("user_name")->setValue( av_name.mDisplayName ); + getChild<LLUICtrl>("user_slid")->setValue( av_name.mSLID ); } // EOF diff --git a/indra/newview/llpanelprofileview.h b/indra/newview/llpanelprofileview.h index 2b67be12e5..dedb617c27 100644 --- a/indra/newview/llpanelprofileview.h +++ b/indra/newview/llpanelprofileview.h @@ -39,6 +39,7 @@ #include "llagent.h" #include "lltooldraganddrop.h" +class LLAvatarName; class LLPanelProfile; class LLPanelProfileTab; class LLTextBox; @@ -99,10 +100,11 @@ protected: private: // LLCacheName will call this function when avatar name is loaded from server. // This is required to display names that have not been cached yet. - void onNameCache( - const LLUUID& id, - const std::string& full_name, - bool is_group); +// void onNameCache( +// const LLUUID& id, +// const std::string& full_name, +// bool is_group); + void onAvatarNameCache(const LLUUID& agent_id, const LLAvatarName& av_name); LLTextBox* mStatusText; AvatarStatusObserver* mAvatarStatusObserver; |