summaryrefslogtreecommitdiff
path: root/indra/newview
diff options
context:
space:
mode:
Diffstat (limited to 'indra/newview')
-rw-r--r--indra/newview/llparticipantlist.cpp15
1 files changed, 14 insertions, 1 deletions
diff --git a/indra/newview/llparticipantlist.cpp b/indra/newview/llparticipantlist.cpp
index e320886ad2..54a837d17d 100644
--- a/indra/newview/llparticipantlist.cpp
+++ b/indra/newview/llparticipantlist.cpp
@@ -577,10 +577,23 @@ bool LLParticipantList::LLParticipantListMenu::enableContextMenuItem(const LLSD&
{
return mUUIDs.front() != gAgentID;
}
- else if (item == "can_allow_text_chat" || "can_moderate_voice" == item)
+ else if (item == "can_allow_text_chat")
{
return isGroupModerator();
}
+ else if ("can_moderate_voice" == item)
+ {
+ if (isGroupModerator())
+ {
+ LLPointer<LLSpeaker> speakerp = mParent.mSpeakerMgr->findSpeaker(mUUIDs.front());
+ if (speakerp.notNull())
+ {
+ // not in voice participants can not be moderated
+ return speakerp->mStatus != LLSpeaker::STATUS_TEXT_ONLY;
+ }
+ }
+ return false;
+ }
else if (item == std::string("can_add"))
{
// We can add friends if: