diff --git a/bigbluebutton-client/src/org/bigbluebutton/modules/chat/views/AddChatTabBox.mxml b/bigbluebutton-client/src/org/bigbluebutton/modules/chat/views/AddChatTabBox.mxml
index b298c9ede9..a61867359a 100755
--- a/bigbluebutton-client/src/org/bigbluebutton/modules/chat/views/AddChatTabBox.mxml
+++ b/bigbluebutton-client/src/org/bigbluebutton/modules/chat/views/AddChatTabBox.mxml
@@ -29,7 +29,7 @@ with BigBlueButton; if not, see .
-
+
@@ -49,10 +49,10 @@ with BigBlueButton; if not, see .
import org.bigbluebutton.core.UsersUtil;
import org.bigbluebutton.core.events.CoreEvent;
import org.bigbluebutton.core.events.LockControlEvent;
+ import org.bigbluebutton.core.events.UserStatusChangedEvent;
import org.bigbluebutton.core.model.LiveMeeting;
import org.bigbluebutton.main.events.UserJoinedEvent;
import org.bigbluebutton.main.events.UserLeftEvent;
- import org.bigbluebutton.main.model.users.events.ChangeMyRole;
import org.bigbluebutton.modules.chat.events.ChatNoiseEnabledEvent;
import org.bigbluebutton.modules.chat.events.ChatOptionsEvent;
import org.bigbluebutton.modules.chat.events.ChatToolbarButtonEvent;
@@ -164,16 +164,20 @@ with BigBlueButton; if not, see .
refreshListStatus();
}
- private function refreshRole(e:ChangeMyRole):void {
+ private function refreshRole(e:Event):void {
clearBtn.visible = clearBtn.enabled = clearBtn.includeInLayout = clrBtnVisible = UsersUtil.amIModerator();
refreshListStatus();
}
private function refreshListStatus():void {
+ handler.disableModeratorsFilter();
+
if (UsersUtil.amIModerator() || UsersUtil.amIPresenter()) return; // Settings only affect viewers.
-
- usersList.enabled = ! LiveMeeting.inst().me.disableMyPrivateChat;
+
+ if (LiveMeeting.inst().me.disableMyPrivateChat) {
+ handler.enableModeratorsFilter();
+ }
}
public function sendSaveEvent():void{
diff --git a/bigbluebutton-client/src/org/bigbluebutton/modules/chat/views/ChatBox.mxml b/bigbluebutton-client/src/org/bigbluebutton/modules/chat/views/ChatBox.mxml
index 858839a848..0c5c43c667 100755
--- a/bigbluebutton-client/src/org/bigbluebutton/modules/chat/views/ChatBox.mxml
+++ b/bigbluebutton-client/src/org/bigbluebutton/modules/chat/views/ChatBox.mxml
@@ -43,7 +43,7 @@ with BigBlueButton; if not, see .
-
+
@@ -59,15 +59,16 @@ with BigBlueButton; if not, see .
import org.as3commons.lang.StringUtils;
import org.as3commons.logging.api.ILogger;
import org.as3commons.logging.api.getClassLogger;
+ import org.bigbluebutton.common.Role;
import org.bigbluebutton.core.Options;
import org.bigbluebutton.core.UsersUtil;
import org.bigbluebutton.core.events.LockControlEvent;
+ import org.bigbluebutton.core.events.UserStatusChangedEvent;
import org.bigbluebutton.core.model.LiveMeeting;
import org.bigbluebutton.main.events.BBBEvent;
import org.bigbluebutton.main.events.ShortcutEvent;
import org.bigbluebutton.main.events.UserJoinedEvent;
import org.bigbluebutton.main.events.UserLeftEvent;
- import org.bigbluebutton.main.model.users.events.ChangeMyRole;
import org.bigbluebutton.modules.chat.ChatUtil;
import org.bigbluebutton.modules.chat.events.ChatEvent;
import org.bigbluebutton.modules.chat.events.ChatHistoryEvent;
@@ -589,11 +590,11 @@ with BigBlueButton; if not, see .
if (publicChat) {
txtMsgArea.enabled = sendBtn.enabled = !LiveMeeting.inst().me.disableMyPublicChat;
} else {
- txtMsgArea.enabled = sendBtn.enabled = !LiveMeeting.inst().me.disableMyPrivateChat;
+ txtMsgArea.enabled = sendBtn.enabled = !LiveMeeting.inst().me.disableMyPrivateChat || LiveMeeting.inst().users.getUser(chatWithUserID).role == Role.MODERATOR;
}
}
- private function refreshRole(e:ChangeMyRole):void {
+ private function refreshRole(e:Event):void {
applyLockSettings();
}
diff --git a/bigbluebutton-client/src/org/bigbluebutton/modules/chat/views/ChatWindowEventHandler.as b/bigbluebutton-client/src/org/bigbluebutton/modules/chat/views/ChatWindowEventHandler.as
index 5387844119..5495984657 100755
--- a/bigbluebutton-client/src/org/bigbluebutton/modules/chat/views/ChatWindowEventHandler.as
+++ b/bigbluebutton-client/src/org/bigbluebutton/modules/chat/views/ChatWindowEventHandler.as
@@ -3,6 +3,7 @@ package org.bigbluebutton.modules.chat.views
import mx.collections.ArrayCollection;
import mx.collections.Sort;
+ import org.bigbluebutton.common.Role;
import org.bigbluebutton.core.UsersUtil;
import org.bigbluebutton.core.model.LiveMeeting;
import org.bigbluebutton.core.model.users.User2x;
@@ -72,6 +73,20 @@ package org.bigbluebutton.modules.chat.views
public function handleUserLeftEvent(userId: String):void {
removeUser(userId, users);
}
+
+ public function enableModeratorsFilter():void {
+ users.filterFunction = filterModeratorsOnly;
+ users.refresh();
+ }
+
+ public function disableModeratorsFilter():void {
+ users.filterFunction = null;
+ users.refresh();
+ }
+
+ private function filterModeratorsOnly(item:Object):Boolean {
+ return LiveMeeting.inst().users.getUser(item.userId).role == Role.MODERATOR;
+ }
private function sortFunction(a:Object, b:Object, array:Array = null):int {
/*