- disable/enable chat for viewer when settings are changed
This commit is contained in:
parent
8549159aad
commit
fb2fd12f3c
@ -305,15 +305,13 @@ package org.bigbluebutton.main.model.users
|
||||
public function applyLockSettings():void {
|
||||
var lockSettings:LockSettingsVO = UserManager.getInstance().getConference().getLockSettings();
|
||||
|
||||
disableMyCam = userLocked && lockSettings.getDisableCam();
|
||||
disableMyMic = userLocked && lockSettings.getDisableMic();
|
||||
disableMyPrivateChat = userLocked && lockSettings.getDisablePrivateChat();
|
||||
disableMyPublicChat = userLocked && lockSettings.getDisablePublicChat();
|
||||
disableMyCam = lockSettings.getDisableCam();
|
||||
disableMyMic = lockSettings.getDisableMic();
|
||||
disableMyPrivateChat = lockSettings.getDisablePrivateChat();
|
||||
disableMyPublicChat = lockSettings.getDisablePublicChat();
|
||||
|
||||
var dispatcher:Dispatcher = new Dispatcher();
|
||||
|
||||
var event:LockControlEvent = new LockControlEvent(LockControlEvent.CHANGED_LOCK_SETTINGS)
|
||||
dispatcher.dispatchEvent(event);
|
||||
dispatcher.dispatchEvent(new LockControlEvent(LockControlEvent.CHANGED_LOCK_SETTINGS));
|
||||
|
||||
//If it's sharing webcam, stop it
|
||||
if(disableMyCam && hasStream){
|
||||
|
20
bigbluebutton-client/src/org/bigbluebutton/modules/chat/views/ChatBox.mxml
Normal file → Executable file
20
bigbluebutton-client/src/org/bigbluebutton/modules/chat/views/ChatBox.mxml
Normal file → Executable file
@ -67,12 +67,15 @@ with BigBlueButton; if not, see <http://www.gnu.org/licenses/>.
|
||||
<mx:Script>
|
||||
<![CDATA[
|
||||
import com.adobe.utils.StringUtil;
|
||||
import com.asfusion.mate.events.Dispatcher;
|
||||
import flash.accessibility.AccessibilityProperties;
|
||||
import com.asfusion.mate.events.Dispatcher;
|
||||
|
||||
import flash.accessibility.AccessibilityProperties;
|
||||
|
||||
import mx.binding.utils.BindingUtils;
|
||||
import mx.collections.ArrayCollection;
|
||||
import mx.controls.Button;
|
||||
import mx.core.ScrollPolicy;
|
||||
import mx.core.ScrollPolicy;
|
||||
|
||||
import org.bigbluebutton.common.LogUtil;
|
||||
import org.bigbluebutton.core.UsersUtil;
|
||||
import org.bigbluebutton.core.events.LockControlEvent;
|
||||
@ -89,8 +92,8 @@ with BigBlueButton; if not, see <http://www.gnu.org/licenses/>.
|
||||
import org.bigbluebutton.modules.chat.events.SendPrivateChatMessageEvent;
|
||||
import org.bigbluebutton.modules.chat.events.SendPublicChatMessageEvent;
|
||||
import org.bigbluebutton.modules.chat.events.TranscriptEvent;
|
||||
import org.bigbluebutton.modules.chat.model.ChatMessage;
|
||||
import org.bigbluebutton.modules.chat.model.ChatConversation;
|
||||
import org.bigbluebutton.modules.chat.model.ChatMessage;
|
||||
import org.bigbluebutton.modules.chat.model.ChatOptions;
|
||||
import org.bigbluebutton.modules.chat.views.ChatMessageRenderer;
|
||||
import org.bigbluebutton.modules.chat.vo.ChatMessageVO;
|
||||
@ -619,14 +622,17 @@ with BigBlueButton; if not, see <http://www.gnu.org/licenses/>.
|
||||
}
|
||||
|
||||
private function lockSettingsChanged(e:Event):void {
|
||||
|
||||
if (UsersUtil.amIModerator()) return; // Settings only affect viewers.
|
||||
|
||||
var userManager:UserManager = UserManager.getInstance();
|
||||
var conference:Conference = userManager.getConference();
|
||||
var me:BBBUser = conference.getMyUser();
|
||||
|
||||
if(publicChat) {
|
||||
sendBtn.enabled = !me.disableMyPublicChat;
|
||||
if (publicChat) {
|
||||
txtMsgArea.enabled = sendBtn.enabled = !me.disableMyPublicChat;
|
||||
} else {
|
||||
sendBtn.enabled = !me.disableMyPrivateChat;
|
||||
txtMsgArea.enabled = sendBtn.enabled = !me.disableMyPrivateChat;
|
||||
}
|
||||
}
|
||||
]]>
|
||||
|
Loading…
Reference in New Issue
Block a user