diff options
author | Nat Goodspeed <nat@lindenlab.com> | 2017-05-04 17:16:12 -0400 |
---|---|---|
committer | Nat Goodspeed <nat@lindenlab.com> | 2017-05-04 17:16:12 -0400 |
commit | a4467e9ffe9dc378451d7bb6b8c70f6c0c42a814 (patch) | |
tree | c6a918a0a3a0d7e1117ca71bfc966e3d6cd4b5ea /indra/newview/llfloaterscriptlimits.cpp | |
parent | 1f2fcc12980dd21659bce493431b7a1b3fe2ef00 (diff) | |
parent | 07ec10781e45b3d92e27e92ddad39cf74fa7ff0b (diff) |
Automated merge with ssh://bitbucket.org/lindenlab/viewer64-c-11
Diffstat (limited to 'indra/newview/llfloaterscriptlimits.cpp')
-rw-r--r-- | indra/newview/llfloaterscriptlimits.cpp | 27 |
1 files changed, 23 insertions, 4 deletions
diff --git a/indra/newview/llfloaterscriptlimits.cpp b/indra/newview/llfloaterscriptlimits.cpp index c14bb4e7ae..5f0587a286 100644 --- a/indra/newview/llfloaterscriptlimits.cpp +++ b/indra/newview/llfloaterscriptlimits.cpp @@ -391,6 +391,14 @@ void LLPanelScriptLimitsRegionMemory::setErrorStatus(S32 status, const std::stri } // callback from the name cache with an owner name to add to the list +void LLPanelScriptLimitsRegionMemory::onAvatarNameCache( + const LLUUID& id, + const LLAvatarName& av_name) +{ + onNameCache(id, av_name.getUserName()); +} + +// callback from the name cache with an owner name to add to the list void LLPanelScriptLimitsRegionMemory::onNameCache( const LLUUID& id, const std::string& full_name) @@ -503,7 +511,9 @@ void LLPanelScriptLimitsRegionMemory::setRegionDetails(LLSD content) } else { - name_is_cached = gCacheName->getFullName(owner_id, owner_buf); // username + LLAvatarName av_name; + name_is_cached = LLAvatarNameCache::get(owner_id, &av_name); + owner_buf = av_name.getUserName(); owner_buf = LLCacheName::buildUsername(owner_buf); } if(!name_is_cached) @@ -511,9 +521,18 @@ void LLPanelScriptLimitsRegionMemory::setRegionDetails(LLSD content) if(std::find(names_requested.begin(), names_requested.end(), owner_id) == names_requested.end()) { names_requested.push_back(owner_id); - gCacheName->get(owner_id, is_group_owned, // username - boost::bind(&LLPanelScriptLimitsRegionMemory::onNameCache, - this, _1, _2)); + if (is_group_owned) + { + gCacheName->getGroup(owner_id, + boost::bind(&LLPanelScriptLimitsRegionMemory::onNameCache, + this, _1, _2)); + } + else + { + LLAvatarNameCache::get(owner_id, + boost::bind(&LLPanelScriptLimitsRegionMemory::onAvatarNameCache, + this, _1, _2)); + } } } } |