Additional improvements to the configuration parsing.
This commit is contained in:
parent
a8102d1936
commit
b59e64b21f
@ -28,7 +28,6 @@
|
|||||||
dependsOn="UsersModule"
|
dependsOn="UsersModule"
|
||||||
privateEnabled="true"
|
privateEnabled="true"
|
||||||
fontSize="12"
|
fontSize="12"
|
||||||
position="top-right"
|
|
||||||
baseTabIndex="801"
|
baseTabIndex="801"
|
||||||
colorPickerIsVisible="false"
|
colorPickerIsVisible="false"
|
||||||
maxMessageLength="1024"
|
maxMessageLength="1024"
|
||||||
@ -66,17 +65,17 @@
|
|||||||
|
|
||||||
<module name="VideoconfModule" url="http://HOST/client/VideoconfModule.swf?v=VERSION"
|
<module name="VideoconfModule" url="http://HOST/client/VideoconfModule.swf?v=VERSION"
|
||||||
uri="rtmp://HOST/video"
|
uri="rtmp://HOST/video"
|
||||||
dependsOn = "UsersModule"
|
dependsOn="UsersModule"
|
||||||
baseTabIndex="401"
|
baseTabIndex="401"
|
||||||
autoStart = "false"
|
autoStart="false"
|
||||||
skipCamSettingsCheck="false"
|
skipCamSettingsCheck="false"
|
||||||
showButton = "true"
|
showButton="true"
|
||||||
applyConvolutionFilter="false"
|
applyConvolutionFilter="false"
|
||||||
convolutionFilter="-1, 0, -1, 0, 6, 0, -1, 0, -1"
|
convolutionFilter="-1, 0, -1, 0, 6, 0, -1, 0, -1"
|
||||||
filterBias="0"
|
filterBias="0"
|
||||||
filterDivisor="4"
|
filterDivisor="4"
|
||||||
displayAvatar = "false"
|
displayAvatar="false"
|
||||||
priorityRatio = "0.67"
|
priorityRatio="0.67"
|
||||||
/>
|
/>
|
||||||
|
|
||||||
<module name="WhiteboardModule" url="http://HOST/client/WhiteboardModule.swf?v=VERSION"
|
<module name="WhiteboardModule" url="http://HOST/client/WhiteboardModule.swf?v=VERSION"
|
||||||
|
@ -87,19 +87,19 @@ package org.bigbluebutton.common {
|
|||||||
logTarget = new TraceTarget();
|
logTarget = new TraceTarget();
|
||||||
} else {
|
} else {
|
||||||
var lxml:XML = BBB.getConfigManager().config.logging;
|
var lxml:XML = BBB.getConfigManager().config.logging;
|
||||||
if (lxml.@enabled != undefined) {
|
if (lxml.@enabled.length() > 0 ) {
|
||||||
loggingEnabled = (lxml.@enabled.toString().toUpperCase() == "TRUE") ? true : false;
|
loggingEnabled = (lxml.@enabled.toString().toUpperCase() == "TRUE");
|
||||||
}
|
}
|
||||||
if (lxml.@target != undefined) {
|
if (lxml.@target.length() > 0 ) {
|
||||||
loggingTargetName = lxml.@target.toString().toLowerCase();
|
loggingTargetName = lxml.@target.toString().toLowerCase();
|
||||||
}
|
}
|
||||||
if (lxml.@level != undefined) {
|
if (lxml.@level.length() > 0 ) {
|
||||||
logLevel = String(lxml.@level).toUpperCase();
|
logLevel = String(lxml.@level).toUpperCase();
|
||||||
}
|
}
|
||||||
if (lxml.@format != undefined) {
|
if (lxml.@format.length() > 0 ) {
|
||||||
logFormat = lxml.@format.toString();
|
logFormat = lxml.@format.toString();
|
||||||
}
|
}
|
||||||
if (lxml.@logPattern != undefined) {
|
if (lxml.@logPattern.length() > 0 ) {
|
||||||
logPattern = lxml.@logPattern.toString();
|
logPattern = lxml.@logPattern.toString();
|
||||||
}
|
}
|
||||||
if (loggingEnabled) {
|
if (loggingEnabled) {
|
||||||
|
@ -30,9 +30,9 @@ package org.bigbluebutton.core {
|
|||||||
|
|
||||||
private static const storage:Dictionary = new Dictionary(true);
|
private static const storage:Dictionary = new Dictionary(true);
|
||||||
|
|
||||||
protected var name:String;
|
private static const parsedOptions:Dictionary = new Dictionary(true);
|
||||||
|
|
||||||
protected var parsed:Boolean;
|
protected var name:String;
|
||||||
|
|
||||||
public static function getOptions(clazz:Class):Options {
|
public static function getOptions(clazz:Class):Options {
|
||||||
var options:Options;
|
var options:Options;
|
||||||
@ -46,8 +46,12 @@ package org.bigbluebutton.core {
|
|||||||
return options;
|
return options;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public static function isParsed(optionName:String):Boolean {
|
||||||
|
return parsedOptions[optionName] != undefined;
|
||||||
|
}
|
||||||
|
|
||||||
public function parseOptions():void {
|
public function parseOptions():void {
|
||||||
if (!parsed) {
|
if (Options.parsedOptions[name] == undefined) {
|
||||||
readOptions();
|
readOptions();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -96,13 +100,13 @@ package org.bigbluebutton.core {
|
|||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
throw new Error("Cannot read undefined property");
|
throw new Error("Cannot parse undefined property type");
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
handleExtraData();
|
handleExtraData();
|
||||||
parsed = true;
|
Options.parsedOptions[name] = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -60,7 +60,7 @@ package org.bigbluebutton.core.managers
|
|||||||
_profiles.splice(0);
|
_profiles.splice(0);
|
||||||
|
|
||||||
var profiles:XML = new XML(e.target.data);
|
var profiles:XML = new XML(e.target.data);
|
||||||
var fallbackLocale:String = profiles.@fallbackLocale != undefined? profiles.@fallbackLocale.toString(): DEFAULT_FALLBACK_LOCALE;
|
var fallbackLocale:String = profiles.@fallbackLocale != undefined ? profiles.@fallbackLocale.toString(): DEFAULT_FALLBACK_LOCALE;
|
||||||
for each (var profile:XML in profiles.children()) {
|
for each (var profile:XML in profiles.children()) {
|
||||||
_profiles.push(new VideoProfile(profile, fallbackLocale));
|
_profiles.push(new VideoProfile(profile, fallbackLocale));
|
||||||
}
|
}
|
||||||
|
@ -95,14 +95,22 @@ package org.bigbluebutton.core.model
|
|||||||
return new XML(config.browserVersions.toXMLString());
|
return new XML(config.browserVersions.toXMLString());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public function get layout():XML {
|
||||||
|
return new XML(config.layout.toXMLString());
|
||||||
|
}
|
||||||
|
|
||||||
public function get meeting():XML {
|
public function get meeting():XML {
|
||||||
return new XML(config.meeting.toXMLString());
|
return new XML(config.meeting.toXMLString());
|
||||||
}
|
}
|
||||||
|
|
||||||
public function get logging():XML {
|
public function get logging():XML {
|
||||||
return new XML(config.logging.toXMLString());
|
return new XML(config.logging.toXMLString());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public function get breakoutRooms():XML {
|
||||||
|
return new XML(config.breakoutRooms.toXMLString());
|
||||||
|
}
|
||||||
|
|
||||||
public function get lock():XML {
|
public function get lock():XML {
|
||||||
if(config.lock == null) return null;
|
if(config.lock == null) return null;
|
||||||
return new XML(config.lock.toXMLString());
|
return new XML(config.lock.toXMLString());
|
||||||
|
@ -488,46 +488,32 @@ package org.bigbluebutton.main.model.users {
|
|||||||
disablePrivateChat:Boolean,
|
disablePrivateChat:Boolean,
|
||||||
disablePublicChat:Boolean,
|
disablePublicChat:Boolean,
|
||||||
lockedLayout:Boolean,
|
lockedLayout:Boolean,
|
||||||
lockOnJoin:Boolean,
|
lockOnJoin:Boolean = true,
|
||||||
lockOnJoinConfigurable:Boolean;
|
lockOnJoinConfigurable:Boolean;
|
||||||
var lockConfig:XML;
|
var lockConfig:XML;
|
||||||
if (config != null) {
|
if (config != null) {
|
||||||
lockConfig = config.lock;
|
lockConfig = config.lock;
|
||||||
}
|
}
|
||||||
try {
|
if (lockConfig.@disableCamForLockedUsers.length() > 0 ) {
|
||||||
disableCam = (lockConfig.@disableCamForLockedUsers.toUpperCase() == "TRUE");
|
disableCam = (lockConfig.@disableCamForLockedUsers.toUpperCase() == "TRUE");
|
||||||
} catch (e:Error) {
|
|
||||||
disableCam = false; //If not set, default to false
|
|
||||||
}
|
}
|
||||||
try {
|
if (lockConfig.@disableMicForLockedUsers.length() > 0 ) {
|
||||||
disableMic = (lockConfig.@disableMicForLockedUsers.toUpperCase() == "TRUE");
|
disableMic = (lockConfig.@disableMicForLockedUsers.toUpperCase() == "TRUE");
|
||||||
} catch (e:Error) {
|
|
||||||
disableMic = false; //If not set, default to false
|
|
||||||
}
|
}
|
||||||
try {
|
if (lockConfig.@disablePrivateChatForLockedUsers.length() > 0 ) {
|
||||||
disablePrivateChat = (lockConfig.@disablePrivateChatForLockedUsers.toUpperCase() == "TRUE");
|
disablePrivateChat = (lockConfig.@disablePrivateChatForLockedUsers.toUpperCase() == "TRUE");
|
||||||
} catch (e:Error) {
|
|
||||||
disablePrivateChat = false; //If not set, default to false
|
|
||||||
}
|
}
|
||||||
try {
|
if (lockConfig.@disablePublicChatForLockedUsers.length() > 0 ) {
|
||||||
disablePublicChat = (lockConfig.@disablePublicChatForLockedUsers.toUpperCase() == "TRUE");
|
disablePublicChat = (lockConfig.@disablePublicChatForLockedUsers.toUpperCase() == "TRUE");
|
||||||
} catch (e:Error) {
|
|
||||||
disablePublicChat = false; //If not set, default to false
|
|
||||||
}
|
}
|
||||||
try {
|
if (lockConfig.@lockLayoutForLockedUsers.length() > 0 ) {
|
||||||
lockedLayout = (lockConfig.@lockLayoutForLockedUsers.toUpperCase() == "TRUE");
|
lockedLayout = (lockConfig.@lockLayoutForLockedUsers.toUpperCase() == "TRUE");
|
||||||
} catch (e:Error) {
|
|
||||||
lockedLayout = false; //If not set, default to false
|
|
||||||
}
|
}
|
||||||
try {
|
if (lockConfig.@lockOnJoin.length() > 0 ) {
|
||||||
lockOnJoin = (lockConfig.@lockOnJoin.toUpperCase() == "TRUE");
|
lockOnJoin = (lockConfig.@lockOnJoin.toUpperCase() == "TRUE");
|
||||||
} catch (e:Error) {
|
|
||||||
lockOnJoin = true; //If not set, default to true
|
|
||||||
}
|
}
|
||||||
try {
|
if (lockConfig.@lockOnJoinConfigurable.length() > 0 ) {
|
||||||
lockOnJoinConfigurable = (lockConfig.@lockOnJoinConfigurable.toUpperCase() == "TRUE");
|
lockOnJoinConfigurable = (lockConfig.@lockOnJoinConfigurable.toUpperCase() == "TRUE");
|
||||||
} catch (e:Error) {
|
|
||||||
lockOnJoinConfigurable = false; //If not set, default to false
|
|
||||||
}
|
}
|
||||||
lockSettings = new LockSettingsVO(disableCam, disableMic, disablePrivateChat, disablePublicChat, lockedLayout, lockOnJoin, lockOnJoinConfigurable);
|
lockSettings = new LockSettingsVO(disableCam, disableMic, disablePrivateChat, disablePublicChat, lockedLayout, lockOnJoin, lockOnJoinConfigurable);
|
||||||
setLockSettings(lockSettings);
|
setLockSettings(lockSettings);
|
||||||
|
@ -19,7 +19,6 @@
|
|||||||
package org.bigbluebutton.modules.caption.views
|
package org.bigbluebutton.modules.caption.views
|
||||||
{
|
{
|
||||||
import mx.controls.TextArea;
|
import mx.controls.TextArea;
|
||||||
import mx.core.IUITextField;
|
|
||||||
import mx.core.UITextField;
|
import mx.core.UITextField;
|
||||||
|
|
||||||
public class TextArea2 extends TextArea
|
public class TextArea2 extends TextArea
|
||||||
|
@ -28,9 +28,6 @@ package org.bigbluebutton.modules.chat.model {
|
|||||||
[Bindable]
|
[Bindable]
|
||||||
public var fontSize:String = "12";
|
public var fontSize:String = "12";
|
||||||
|
|
||||||
[Bindable]
|
|
||||||
public var position:String = "top-right";
|
|
||||||
|
|
||||||
[Bindable]
|
[Bindable]
|
||||||
public var baseTabIndex:int = 801;
|
public var baseTabIndex:int = 801;
|
||||||
|
|
||||||
|
@ -45,6 +45,7 @@ with BigBlueButton; if not, see <http://www.gnu.org/licenses/>.
|
|||||||
import org.bigbluebutton.common.events.LocaleChangeEvent;
|
import org.bigbluebutton.common.events.LocaleChangeEvent;
|
||||||
import org.bigbluebutton.core.KeyboardUtil;
|
import org.bigbluebutton.core.KeyboardUtil;
|
||||||
import org.bigbluebutton.main.events.ShortcutEvent;
|
import org.bigbluebutton.main.events.ShortcutEvent;
|
||||||
|
import org.bigbluebutton.main.views.MainCanvas;
|
||||||
import org.bigbluebutton.modules.chat.model.ChatOptions;
|
import org.bigbluebutton.modules.chat.model.ChatOptions;
|
||||||
import org.bigbluebutton.util.i18n.ResourceUtil;
|
import org.bigbluebutton.util.i18n.ResourceUtil;
|
||||||
|
|
||||||
@ -56,7 +57,7 @@ with BigBlueButton; if not, see <http://www.gnu.org/licenses/>.
|
|||||||
[Bindable] public var chatOptions:ChatOptions;
|
[Bindable] public var chatOptions:ChatOptions;
|
||||||
|
|
||||||
public function getPrefferedPosition():String{
|
public function getPrefferedPosition():String{
|
||||||
return chatOptions.position;
|
return MainCanvas.TOP_RIGHT;
|
||||||
}
|
}
|
||||||
|
|
||||||
private function onCreationComplete():void {
|
private function onCreationComplete():void {
|
||||||
|
Loading…
Reference in New Issue
Block a user