summaryrefslogtreecommitdiff
path: root/indra/newview/llpanelgroupgeneral.cpp
diff options
context:
space:
mode:
authorIma Mechanique <ima.mechanique@secondlife.com>2013-06-26 17:39:23 +0100
committerIma Mechanique <ima.mechanique@secondlife.com>2013-06-26 17:39:23 +0100
commitb615858d6c41c29b3b610ec0dba09f30b1f8b3a8 (patch)
tree2b193625c9ed4a0ca36e5b5f99f1cc765e979d74 /indra/newview/llpanelgroupgeneral.cpp
parente63d92ab504d74399cae2a9cc7625ef3ec330c38 (diff)
parent2655c7a17ae38a073dcf8f05b0127b68edc34c95 (diff)
Merging last four months of development
Diffstat (limited to 'indra/newview/llpanelgroupgeneral.cpp')
-rwxr-xr-x[-rw-r--r--]indra/newview/llpanelgroupgeneral.cpp18
1 files changed, 14 insertions, 4 deletions
diff --git a/indra/newview/llpanelgroupgeneral.cpp b/indra/newview/llpanelgroupgeneral.cpp
index 993ffb7825..0cd93b330a 100644..100755
--- a/indra/newview/llpanelgroupgeneral.cpp
+++ b/indra/newview/llpanelgroupgeneral.cpp
@@ -79,13 +79,18 @@ LLPanelGroupGeneral::LLPanelGroupGeneral()
mCtrlReceiveNotices(NULL),
mCtrlListGroup(NULL),
mActiveTitleLabel(NULL),
- mComboActiveTitle(NULL)
+ mComboActiveTitle(NULL),
+ mAvatarNameCacheConnection()
{
}
LLPanelGroupGeneral::~LLPanelGroupGeneral()
{
+ if (mAvatarNameCacheConnection.connected())
+ {
+ mAvatarNameCacheConnection.disconnect();
+ }
}
BOOL LLPanelGroupGeneral::postBuild()
@@ -727,9 +732,12 @@ void LLPanelGroupGeneral::updateMembers()
else
{
// If name is not cached, onNameCache() should be called when it is cached and add this member to list.
- LLAvatarNameCache::get(mMemberProgress->first,
- boost::bind(&LLPanelGroupGeneral::onNameCache,
- this, gdatap->getMemberVersion(), member, _2));
+ // *TODO : Use a callback per member, not for the panel group.
+ if (mAvatarNameCacheConnection.connected())
+ {
+ mAvatarNameCacheConnection.disconnect();
+ }
+ mAvatarNameCacheConnection = LLAvatarNameCache::get(mMemberProgress->first, boost::bind(&LLPanelGroupGeneral::onNameCache, this, gdatap->getMemberVersion(), member, _2));
}
}
@@ -769,6 +777,8 @@ void LLPanelGroupGeneral::addMember(LLGroupMemberData* member)
void LLPanelGroupGeneral::onNameCache(const LLUUID& update_id, LLGroupMemberData* member, const LLAvatarName& av_name)
{
+ mAvatarNameCacheConnection.disconnect();
+
LLGroupMgrGroupData* gdatap = LLGroupMgr::getInstance()->getGroupData(mGroupID);
if (!gdatap