summaryrefslogtreecommitdiff
path: root/indra/newview/llpanelgrouproles.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'indra/newview/llpanelgrouproles.cpp')
-rw-r--r--indra/newview/llpanelgrouproles.cpp34
1 files changed, 30 insertions, 4 deletions
diff --git a/indra/newview/llpanelgrouproles.cpp b/indra/newview/llpanelgrouproles.cpp
index da7922d657..b6c58808ae 100644
--- a/indra/newview/llpanelgrouproles.cpp
+++ b/indra/newview/llpanelgrouproles.cpp
@@ -42,6 +42,7 @@
#include "lliconctrl.h"
#include "lllineeditor.h"
#include "llnamelistctrl.h"
+#include "llnotifications.h"
#include "llnotificationsutil.h"
#include "llnotify.h"
#include "llpanelgrouproles.h"
@@ -1101,10 +1102,33 @@ void LLPanelGroupMembersSubTab::handleEjectMembers()
mMembersList->deleteSelectedItems();
+ sendEjectNotifications(mGroupID, selected_members);
+
LLGroupMgr::getInstance()->sendGroupMemberEjects(mGroupID,
selected_members);
}
+void LLPanelGroupMembersSubTab::sendEjectNotifications(const LLUUID& group_id, const std::vector<LLUUID>& selected_members)
+{
+ LLGroupMgrGroupData* group_data = LLGroupMgr::getInstance()->getGroupData(group_id);
+
+ if (group_data)
+ {
+ for (std::vector<LLUUID>::const_iterator i = selected_members.begin(); i != selected_members.end(); ++i)
+ {
+ LLSD args;
+ std::string name;
+
+ gCacheName->getFullName(*i, name);
+
+ args["AVATAR_NAME"] = name;
+ args["GROUP_NAME"] = group_data->mName;
+
+ LLNotifications::instance().add(LLNotification::Params("EjectAvatarFromGroup").substitutions(args));
+ }
+ }
+}
+
void LLPanelGroupMembersSubTab::handleRoleCheck(const LLUUID& role_id,
LLRoleMemberChangeType type)
{
@@ -1544,9 +1568,6 @@ void LLPanelGroupMembersSubTab::updateMembers()
mPendingMemberUpdate = FALSE;
// Rebuild the members list.
- mMembersList->deleteAllItems();
-
- lldebugs << "LLPanelGroupMembersSubTab::updateMembers()" << llendl;
LLGroupMgrGroupData* gdatap = LLGroupMgr::getInstance()->getGroupData(mGroupID);
if (!gdatap)
@@ -1563,7 +1584,12 @@ void LLPanelGroupMembersSubTab::updateMembers()
{
return;
}
-
+
+ //cleanup list only for first iretation
+ if(mMemberProgress == gdatap->mMembers.begin())
+ mMembersList->deleteAllItems();
+
+
LLGroupMgrGroupData::member_list_t::iterator end = gdatap->mMembers.end();
S32 i = 0;