diff options
author | maxim_productengine <mnikolenko@productengine.com> | 2018-07-03 14:22:15 +0300 |
---|---|---|
committer | maxim_productengine <mnikolenko@productengine.com> | 2018-07-03 14:22:15 +0300 |
commit | 7ee5ee3dfdda7809c1ff3c40d6de2f01e5e207aa (patch) | |
tree | 0579eae53869f9581598fca4e809d699dde1fe8f /indra/newview/llfloaterregioninfo.cpp | |
parent | d154dc08923f607fbd25652eb9515af65b6269f8 (diff) |
MAINT-8582 FIXED The message "Group is already in the list" is not displayed
Diffstat (limited to 'indra/newview/llfloaterregioninfo.cpp')
-rw-r--r-- | indra/newview/llfloaterregioninfo.cpp | 16 |
1 files changed, 15 insertions, 1 deletions
diff --git a/indra/newview/llfloaterregioninfo.cpp b/indra/newview/llfloaterregioninfo.cpp index a931351feb..9f7fa82529 100644 --- a/indra/newview/llfloaterregioninfo.cpp +++ b/indra/newview/llfloaterregioninfo.cpp @@ -3463,6 +3463,20 @@ void LLPanelEstateAccess::onClickRemoveEstateManager() // Special case callback for groups, since it has different callback format than names void LLPanelEstateAccess::addAllowedGroup2(LLUUID id) { + LLPanelEstateAccess* panel = LLFloaterRegionInfo::getPanelAccess(); + if (panel) + { + LLNameListCtrl* group_list = panel->getChild<LLNameListCtrl>("allowed_group_name_list"); + LLScrollListItem* item = group_list->getNameItemByAgentId(id); + if (item) + { + LLSD args; + args["GROUP"] = item->getColumn(0)->getValue().asString(); + LLNotificationsUtil::add("GroupIsAlreadyInList", args); + return; + } + } + LLSD payload; payload["operation"] = (S32)ESTATE_ACCESS_ALLOWED_GROUP_ADD; payload["dialog_name"] = "EstateAllowedGroupAdd"; @@ -4019,7 +4033,7 @@ void LLPanelEstateAccess::requestEstateGetAccessCoro(std::string url) for (LLSD::array_const_iterator it = result["AllowedGroups"].beginArray(); it != result["AllowedGroups"].endArray(); ++it) { LLUUID id = (*it)["id"].asUUID(); - allowed_group_name_list->addNameItem(id); + allowed_group_name_list->addGroupNameItem(id); } allowed_group_name_list->sortByName(TRUE); } |