MAINT-8587 FIXED "(waiting)" instead of a group name in the Allowed Groups list.
parent
7ee5ee3dfd
commit
a1466bcdaf
|
|
@ -3835,16 +3835,19 @@ bool LLPanelEstateAccess::accessCoreConfirm(const LLSD& notification, const LLSD
|
|||
|
||||
sendEstateAccessDelta(flags, id);
|
||||
|
||||
// fill the name list for confirmation
|
||||
LLAvatarName av_name;
|
||||
if (LLAvatarNameCache::get(id, &av_name))
|
||||
if ((flags & (ESTATE_ACCESS_ALLOWED_GROUP_ADD | ESTATE_ACCESS_ALLOWED_GROUP_REMOVE)) == 0)
|
||||
{
|
||||
if (!names.empty())
|
||||
// fill the name list for confirmation
|
||||
LLAvatarName av_name;
|
||||
if (LLAvatarNameCache::get(id, &av_name))
|
||||
{
|
||||
names += ", ";
|
||||
single = false;
|
||||
if (!names.empty())
|
||||
{
|
||||
names += ", ";
|
||||
single = false;
|
||||
}
|
||||
names += av_name.getCompleteName();
|
||||
}
|
||||
names += av_name.getCompleteName();
|
||||
}
|
||||
}
|
||||
LLPanelEstateAccess* panel = LLFloaterRegionInfo::getPanelAccess();
|
||||
|
|
|
|||
|
|
@ -313,8 +313,19 @@ LLScrollListItem* LLNameListCtrl::addNameItemRow(
|
|||
switch(name_item.target)
|
||||
{
|
||||
case GROUP:
|
||||
gCacheName->getGroupName(id, fullname);
|
||||
// fullname will be "nobody" if group not found
|
||||
if (!gCacheName->getGroupName(id, fullname))
|
||||
{
|
||||
avatar_name_cache_connection_map_t::iterator it = mGroupNameCacheConnections.find(id);
|
||||
if (it != mGroupNameCacheConnections.end())
|
||||
{
|
||||
if (it->second.connected())
|
||||
{
|
||||
it->second.disconnect();
|
||||
}
|
||||
mGroupNameCacheConnections.erase(it);
|
||||
}
|
||||
mGroupNameCacheConnections[id] = gCacheName->getGroup(id, boost::bind(&LLNameListCtrl::onGroupNameCache, this, _1, _2, item->getHandle()));
|
||||
}
|
||||
break;
|
||||
case SPECIAL:
|
||||
// just use supplied name
|
||||
|
|
@ -493,6 +504,31 @@ void LLNameListCtrl::onAvatarNameCache(const LLUUID& agent_id,
|
|||
dirtyColumns();
|
||||
}
|
||||
|
||||
void LLNameListCtrl::onGroupNameCache(const LLUUID& group_id, const std::string name, LLHandle<LLNameListItem> item)
|
||||
{
|
||||
avatar_name_cache_connection_map_t::iterator it = mGroupNameCacheConnections.find(group_id);
|
||||
if (it != mGroupNameCacheConnections.end())
|
||||
{
|
||||
if (it->second.connected())
|
||||
{
|
||||
it->second.disconnect();
|
||||
}
|
||||
mGroupNameCacheConnections.erase(it);
|
||||
}
|
||||
|
||||
LLNameListItem* list_item = item.get();
|
||||
if (list_item && list_item->getUUID() == group_id)
|
||||
{
|
||||
LLScrollListCell* cell = list_item->getColumn(mNameColumnIndex);
|
||||
if (cell)
|
||||
{
|
||||
cell->setValue(name);
|
||||
setNeedsSort();
|
||||
}
|
||||
}
|
||||
|
||||
dirtyColumns();
|
||||
}
|
||||
|
||||
void LLNameListCtrl::updateColumns(bool force_update)
|
||||
{
|
||||
|
|
|
|||
|
|
@ -173,6 +173,7 @@ public:
|
|||
private:
|
||||
void showInspector(const LLUUID& avatar_id, bool is_group, bool is_experience = false);
|
||||
void onAvatarNameCache(const LLUUID& agent_id, const LLAvatarName& av_name, std::string suffix, std::string prefix, LLHandle<LLNameListItem> item);
|
||||
void onGroupNameCache(const LLUUID& group_id, const std::string name, LLHandle<LLNameListItem> item);
|
||||
|
||||
private:
|
||||
S32 mNameColumnIndex;
|
||||
|
|
@ -181,6 +182,7 @@ private:
|
|||
bool mShortNames; // display name only, no SLID
|
||||
typedef std::map<LLUUID, boost::signals2::connection> avatar_name_cache_connection_map_t;
|
||||
avatar_name_cache_connection_map_t mAvatarNameCacheConnections;
|
||||
avatar_name_cache_connection_map_t mGroupNameCacheConnections;
|
||||
|
||||
S32 mPendingLookupsRemaining;
|
||||
namelist_complete_signal_t mNameListCompleteSignal;
|
||||
|
|
|
|||
Loading…
Reference in New Issue