diff --git a/bigbluebutton-client/src/ViewersModule.mxml b/bigbluebutton-client/src/ViewersModule.mxml index 0490d3d0a7..531e7d2f00 100644 --- a/bigbluebutton-client/src/ViewersModule.mxml +++ b/bigbluebutton-client/src/ViewersModule.mxml @@ -12,8 +12,7 @@ private var _moduleId:String = "ViewersModule"; private var _moduleName:String = "Viewers Module"; - private var _uri:String = "rtmp://localhost/conference/85115"; - private var _username:String = "ralam"; + private var _attributes:Object; private function onCreationComplete():void { trace("ViewersModule Initialized"); @@ -35,23 +34,17 @@ return _moduleName; } - public function set uri(uri:String):void { - _uri = uri; - } - public function get uri():String { - return _uri; - } - - public function set username(name:String):void { - _username = name; + return _attributes.uri + "/"; } + public function get username():String { - return _username; + return _attributes.username; } public function start(attributes:Object):void { + _attributes = attributes; ViewersFacade.getInstance().startup(this); } diff --git a/bigbluebutton-client/src/conf/modules.xml b/bigbluebutton-client/src/conf/modules.xml index 230fe5b6b3..2e4ce96919 100644 --- a/bigbluebutton-client/src/conf/modules.xml +++ b/bigbluebutton-client/src/conf/modules.xml @@ -1,6 +1,6 @@ - + \ No newline at end of file diff --git a/bigbluebutton-client/src/org/bigbluebutton/common/Constants.as b/bigbluebutton-client/src/org/bigbluebutton/common/Constants.as index 77f9cb20da..c3988c499d 100644 --- a/bigbluebutton-client/src/org/bigbluebutton/common/Constants.as +++ b/bigbluebutton-client/src/org/bigbluebutton/common/Constants.as @@ -32,11 +32,11 @@ package org.bigbluebutton.common { public static const RELATIVE_FILE_UPLOAD:String = "/bigbluebutton/file"; - public static var red5Host:String; - public static var presentationHost:String; - public static var relativeFileUpload:String = RELATIVE_FILE_UPLOAD; +// public static var red5Host:String; +// public static var presentationHost:String; +// public static var relativeFileUpload:String = RELATIVE_FILE_UPLOAD; - public static const TEST_URL:String = testURL(); +// public static const TEST_URL:String = testURL(); public static const VERSION:String = "0.35a"; @@ -46,6 +46,7 @@ package org.bigbluebutton.common * This is basicaly meant to ease development. Call this method when the application starts up. * */ +/* public static function setHost():void{ if (testURL() != null){ red5Host = testURL(); @@ -78,6 +79,6 @@ package org.bigbluebutton.common return url; } - +*/ } } \ No newline at end of file diff --git a/bigbluebutton-client/src/org/bigbluebutton/main/view/MainApplicationShellMediator.as b/bigbluebutton-client/src/org/bigbluebutton/main/view/MainApplicationShellMediator.as index fed257e675..8ed9a71ced 100644 --- a/bigbluebutton-client/src/org/bigbluebutton/main/view/MainApplicationShellMediator.as +++ b/bigbluebutton-client/src/org/bigbluebutton/main/view/MainApplicationShellMediator.as @@ -45,10 +45,7 @@ package org.bigbluebutton.main.view public function MainApplicationShellMediator( viewComponent:MainApplicationShell ) { - super( NAME, viewComponent ); - trace("red5:" + Constants.red5Host); - trace("present:" + Constants.presentationHost); - trace("url:" + Constants.TEST_URL); + super( NAME, viewComponent ); viewComponent.toolbar.addEventListener(MainApplicationConstants.LOGOUT_EVENT, onLogoutEventHandler); } diff --git a/bigbluebutton-client/src/org/bigbluebutton/main/view/components/MainApplicationShell.mxml b/bigbluebutton-client/src/org/bigbluebutton/main/view/components/MainApplicationShell.mxml index c52cd51651..1720bd446e 100644 --- a/bigbluebutton-client/src/org/bigbluebutton/main/view/components/MainApplicationShell.mxml +++ b/bigbluebutton-client/src/org/bigbluebutton/main/view/components/MainApplicationShell.mxml @@ -20,7 +20,6 @@ protected function initializeShell():void { - Constants.setHost(); trace("before startup in initShell"); facade.startup(this); trace("After startup in initShell"); diff --git a/bigbluebutton-client/src/org/bigbluebutton/modules/viewers/controller/StartupCommand.as b/bigbluebutton-client/src/org/bigbluebutton/modules/viewers/controller/StartupCommand.as index 29c9f0304e..d5041b93ef 100644 --- a/bigbluebutton-client/src/org/bigbluebutton/modules/viewers/controller/StartupCommand.as +++ b/bigbluebutton-client/src/org/bigbluebutton/modules/viewers/controller/StartupCommand.as @@ -41,7 +41,7 @@ package org.bigbluebutton.modules.viewers.controller facade.registerMediator(new ViewersModuleMediator(m)); facade.registerMediator(new ViewersEndpointMediator(m)); - facade.registerMediator(new JoinWindowMediator()); + facade.registerMediator(new JoinWindowMediator(m)); facade.registerMediator(new ViewersWindowMediator()); facade.registerProxy(new ViewersProxy(m.uri)); trace('Sending MODULE_STARTED for ViewersModule'); diff --git a/bigbluebutton-client/src/org/bigbluebutton/modules/viewers/model/services/NetConnectionDelegate.as b/bigbluebutton-client/src/org/bigbluebutton/modules/viewers/model/services/NetConnectionDelegate.as index 8213b46bf2..534c12b3ba 100644 --- a/bigbluebutton-client/src/org/bigbluebutton/modules/viewers/model/services/NetConnectionDelegate.as +++ b/bigbluebutton-client/src/org/bigbluebutton/modules/viewers/model/services/NetConnectionDelegate.as @@ -65,8 +65,7 @@ package org.bigbluebutton.modules.viewers.model.services _netConnection.addEventListener( SecurityErrorEvent.SECURITY_ERROR, netSecurityError ); _netConnection.addEventListener( IOErrorEvent.IO_ERROR, netIOError ); - try { - trace( "Connecting to " + _uri + " " + room + " " + username + " " + password); + try { _netConnection.connect(_uri, room, username, password ); } catch( e : ArgumentError ) { diff --git a/bigbluebutton-client/src/org/bigbluebutton/modules/viewers/view/JoinWindowMediator.as b/bigbluebutton-client/src/org/bigbluebutton/modules/viewers/view/JoinWindowMediator.as index 7368040af0..95c6d608d9 100644 --- a/bigbluebutton-client/src/org/bigbluebutton/modules/viewers/view/JoinWindowMediator.as +++ b/bigbluebutton-client/src/org/bigbluebutton/modules/viewers/view/JoinWindowMediator.as @@ -21,9 +21,9 @@ package org.bigbluebutton.modules.viewers.view { import flash.events.Event; import flash.events.KeyboardEvent; - import flash.system.Capabilities; import org.bigbluebutton.common.Constants; + import org.bigbluebutton.common.IBigBlueButtonModule; import org.bigbluebutton.modules.viewers.ViewersFacade; import org.bigbluebutton.modules.viewers.ViewersModuleConstants; import org.bigbluebutton.modules.viewers.model.ViewersProxy; @@ -41,6 +41,7 @@ package org.bigbluebutton.modules.viewers.view { public static const NAME:String = "JoinWindowMediator"; + private var _module:IBigBlueButtonModule; private var _joinWindow:JoinWindow = new JoinWindow(); public static const LOGIN:String = "Attempt Login"; @@ -49,9 +50,10 @@ package org.bigbluebutton.modules.viewers.view * @param view * */ - public function JoinWindowMediator() + public function JoinWindowMediator(module:IBigBlueButtonModule) { - super(NAME); + super(NAME, module); + _module = module; _joinWindow.addEventListener(LOGIN, login); _joinWindow.addEventListener(KeyboardEvent.KEY_DOWN, keyPressed); } @@ -142,8 +144,7 @@ package org.bigbluebutton.modules.viewers.view } _joinWindow.lblNote.text = "Attempting to Login"; - var completeHost:String = "rtmp://" + Constants.red5Host + "/conference/" + room; - trace("loggin in: " + completeHost + " " + name + " " + password + " " + room); + var completeHost:String = _module.uri + room; proxy.connect(completeHost, room, name, password); }