Author: solomax
Date: Wed Dec 14 05:14:19 2016
New Revision: 1774125

URL: http://svn.apache.org/viewvc?rev=1774125&view=rev
Log:
[OPENMEETINGS-1454] self audio/video refactoring

Modified:
    
openmeetings/application/branches/3.2.x/openmeetings-core/src/main/java/org/apache/openmeetings/core/remote/red5/ScopeApplicationAdapter.java
    
openmeetings/application/branches/3.2.x/openmeetings-flash/src/main/swf/base/externalJavaScript.lzx
    
openmeetings/application/branches/3.2.x/openmeetings-flash/src/main/swf/base/hibernate/hibRtmpConnection.lzx
    
openmeetings/application/branches/3.2.x/openmeetings-flash/src/main/swf/base/mainMethods.lzx
    
openmeetings/application/branches/3.2.x/openmeetings-flash/src/main/swf/commonVideoViewContentSWF10.lzx
    
openmeetings/application/branches/3.2.x/openmeetings-flash/src/main/swf/video/baseVideoObject.lzx
    
openmeetings/application/branches/3.2.x/openmeetings-flash/src/main/swf/video/editRecordStreamSWF10.lzx
    
openmeetings/application/branches/3.2.x/openmeetings-flash/src/main/swf/video/videoUserProfilePicSWF10.lzx
    
openmeetings/application/trunk/openmeetings-core/src/main/java/org/apache/openmeetings/core/remote/red5/ScopeApplicationAdapter.java

Modified: 
openmeetings/application/branches/3.2.x/openmeetings-core/src/main/java/org/apache/openmeetings/core/remote/red5/ScopeApplicationAdapter.java
URL: 
http://svn.apache.org/viewvc/openmeetings/application/branches/3.2.x/openmeetings-core/src/main/java/org/apache/openmeetings/core/remote/red5/ScopeApplicationAdapter.java?rev=1774125&r1=1774124&r2=1774125&view=diff
==============================================================================
--- 
openmeetings/application/branches/3.2.x/openmeetings-core/src/main/java/org/apache/openmeetings/core/remote/red5/ScopeApplicationAdapter.java
 (original)
+++ 
openmeetings/application/branches/3.2.x/openmeetings-core/src/main/java/org/apache/openmeetings/core/remote/red5/ScopeApplicationAdapter.java
 Wed Dec 14 05:14:19 2016
@@ -1530,31 +1530,6 @@ public class ScopeApplicationAdapter ext
                return 1;
        }
 
-       public int sendVarsModeratorGeneral(Object vars) {
-               log.debug("*..*sendVars: " + vars);
-               try {
-                       IConnection current = Red5.getConnectionLocal();
-                       Client currentClient = 
sessionManager.getClientByStreamId(current.getClient().getId(), null);
-
-                       log.debug("***** id: " + currentClient.getStreamid());
-
-                       boolean ismod = currentClient.getIsMod();
-
-                       if (ismod) {
-                               log.debug("CurrentScope :" + 
current.getScope().getName());
-                               // Send to all Clients of the same Scope
-                               
sendMessageToCurrentScope("sendVarsToModeratorGeneral", vars, false);
-                               return 1;
-                       } else {
-                               // log.debug("*..*you are not allowed to send: 
"+ismod);
-                               return -1;
-                       }
-               } catch (Exception err) {
-                       log.error("[sendVarsModeratorGeneral]", err);
-               }
-               return -1;
-       }
-
        public int sendMessage(Object newMessage) {
                sendMessageToCurrentScope("sendVarsToMessage", newMessage, 
false);
                return 1;

Modified: 
openmeetings/application/branches/3.2.x/openmeetings-flash/src/main/swf/base/externalJavaScript.lzx
URL: 
http://svn.apache.org/viewvc/openmeetings/application/branches/3.2.x/openmeetings-flash/src/main/swf/base/externalJavaScript.lzx?rev=1774125&r1=1774124&r2=1774125&view=diff
==============================================================================
--- 
openmeetings/application/branches/3.2.x/openmeetings-flash/src/main/swf/base/externalJavaScript.lzx
 (original)
+++ 
openmeetings/application/branches/3.2.x/openmeetings-flash/src/main/swf/base/externalJavaScript.lzx
 Wed Dec 14 05:14:19 2016
@@ -33,7 +33,7 @@
        ExternalInterface.addCallback("getBrowserLangCallback", 
getBrowserLangCallback);
        ExternalInterface.addCallback("showAvSettings", function(isInterview) {
                if ($debug) Debug.write("showAvSettings ", isInterview);
-               
canvas.commonVideoViewContent.createEditRecordStream(isInterview, true, false);
+               
canvas.commonVideoViewContent.createEditRecordStream(isInterview);
        });
        
        var redirectToUrlReturnObject = null;

Modified: 
openmeetings/application/branches/3.2.x/openmeetings-flash/src/main/swf/base/hibernate/hibRtmpConnection.lzx
URL: 
http://svn.apache.org/viewvc/openmeetings/application/branches/3.2.x/openmeetings-flash/src/main/swf/base/hibernate/hibRtmpConnection.lzx?rev=1774125&r1=1774124&r2=1774125&view=diff
==============================================================================
--- 
openmeetings/application/branches/3.2.x/openmeetings-flash/src/main/swf/base/hibernate/hibRtmpConnection.lzx
 (original)
+++ 
openmeetings/application/branches/3.2.x/openmeetings-flash/src/main/swf/base/hibernate/hibRtmpConnection.lzx
 Wed Dec 14 05:14:19 2016
@@ -758,7 +758,7 @@
                </netRemoteCallHib>
                
                <netRemoteCallHib name="setCanDraw" 
funcname="whiteboardservice.setCanDraw"
-                                          remotecontext="$once{ canvas.thishib 
}">
+                               remotecontext="$once{ canvas.thishib }">
                        <attribute name="publicSID" value="" type="string" />
                        <attribute name="canDraw" value="true" type="boolean" />
                        <netparam><method name="getValue">return 
canvas.sessionId;</method></netparam>
@@ -769,11 +769,11 @@
                                        //The onResult-Handler will be called 
be the rtmpconnection
                                        if ($debug) Debug.write("setCanDraw : 
",value);
                                ]]>
-                       </handler>   
+                       </handler>
                </netRemoteCallHib>
                
                <netRemoteCallHib name="setCanShare" 
funcname="whiteboardservice.setCanShare"
-                                          remotecontext="$once{ canvas.thishib 
}">
+                               remotecontext="$once{ canvas.thishib }">
                        <attribute name="publicSID" value="" type="string" />
                        <attribute name="canShare" value="true" type="boolean" 
/>
                        <netparam><method name="getValue">return 
canvas.sessionId;</method></netparam>
@@ -784,11 +784,11 @@
                                        //The onResult-Handler will be called 
be the rtmpconnection
                                        if ($debug) Debug.write("setCanShare : 
",value);
                                ]]>
-                       </handler>   
+                       </handler>
                </netRemoteCallHib>
                
                <netRemoteCallHib name="setCanRemote" 
funcname="whiteboardservice.setCanRemote"
-                                          remotecontext="$once{ canvas.thishib 
}">
+                               remotecontext="$once{ canvas.thishib }">
                        <attribute name="publicSID" value="" type="string" />
                        <attribute name="canRemote" value="true" type="boolean" 
/>
                        <netparam><method name="getValue">return 
canvas.sessionId;</method></netparam>
@@ -799,7 +799,7 @@
                                        //The onResult-Handler will be called 
be the rtmpconnection
                                        if ($debug) Debug.write("setCanRemote : 
",value);
                                ]]>
-                       </handler>   
+                       </handler>
                </netRemoteCallHib>
                
                <method name="setNewModeratorByList" args="value">
@@ -812,7 +812,7 @@
                        //Update Moderation Flag
                        canvas.updateModerationFlag();
                ]]>
-               </method> 
+               </method>
                
                <netRemoteCallHib name="sendMessage" funcname="sendMessage">
                        <netparam name="vars"><method name="getValue">return 
canvas.objMessage;</method></netparam>
@@ -822,8 +822,8 @@
                                //Debug.write("getValue : ",value);
                                
                                ]]>
-                       </handler>   
-               </netRemoteCallHib> 
+                       </handler>
+               </netRemoteCallHib>
                
                <netRemoteCallHib name="sendMessageAll" 
funcname="sendMessageAll">
                        <netparam name="vars"><method name="getValue">return 
canvas.objMessage;</method></netparam>
@@ -832,8 +832,8 @@
                                //The onResult-Handler will be called be the 
rtmpconnection
                                //Debug.write("getValue : ",value);
                                ]]>
-                       </handler>   
-               </netRemoteCallHib> 
+                       </handler>
+               </netRemoteCallHib>
                
                <method name="clientUpdated" args="client">
                <![CDATA[
@@ -851,11 +851,7 @@
                                canvas.setAttribute("canVideo", 
client.canVideo);
                                
                                if (client.isBroadcasting) {
-                                       if (canvas.thishib.modus == 
"interview") {
-                                               
canvas._drawarea.newInterviewStarting(client);
-                                       } else {
-                                               
canvas.commonVideoViewContent.createEditRecordStream(false, false, false);
-                                       }
+                                       
canvas.commonVideoViewContent.startAvBroadcast();
                                        
canvas.setAttribute("lastBroadCastingUser", client);
                                } else {
                                        
canvas.commonVideoViewContent.removeVideoByUser(canvas.publicSID);
@@ -897,17 +893,6 @@
                        }
                ]]>
                </method>
-               
-               <netRemoteCallHib name="sendVarsModeratorGeneral" 
funcname="sendVarsModeratorGeneral">
-                       <netparam name="vars"><method name="getValue">return 
canvas.VarsModeratorGeneral;</method></netparam>
-                       <handler name="ondata" args="value">
-                       <![CDATA[
-                               //The onResult-Handler will be called be the 
rtmpconnection
-                               //Debug.write("sendVarsModeratorGeneral : 
",value);
-                               
-                       ]]>
-                       </handler>
-               </netRemoteCallHib>
 
                <netRemoteCallHib name="sendMessageWithClient" 
funcname="sendMessageWithClient"
                                remotecontext="$once{ canvas.thishib }" >

Modified: 
openmeetings/application/branches/3.2.x/openmeetings-flash/src/main/swf/base/mainMethods.lzx
URL: 
http://svn.apache.org/viewvc/openmeetings/application/branches/3.2.x/openmeetings-flash/src/main/swf/base/mainMethods.lzx?rev=1774125&r1=1774124&r2=1774125&view=diff
==============================================================================
--- 
openmeetings/application/branches/3.2.x/openmeetings-flash/src/main/swf/base/mainMethods.lzx
 (original)
+++ 
openmeetings/application/branches/3.2.x/openmeetings-flash/src/main/swf/base/mainMethods.lzx
 Wed Dec 14 05:14:19 2016
@@ -194,12 +194,9 @@
                        new lz.editRecordStreamSWF10(canvas.main_content,{
                                allowDragging: false,
                                dropShadow: false,
-                               standalone: true,
                                name: "editRecordStream",
                                doDefaultAnimation: false,
-                               isInterview: true,
-                               interviewPodId: 
this.parent.parent.interviewPodId,
-                               isSyncUpdate: true,
+                               isInterview: false,
                                x: 0, y: 0, initY: 0
                                });
                        var rtmpCon = new lz.rtmpConnection(canvas, {

Modified: 
openmeetings/application/branches/3.2.x/openmeetings-flash/src/main/swf/commonVideoViewContentSWF10.lzx
URL: 
http://svn.apache.org/viewvc/openmeetings/application/branches/3.2.x/openmeetings-flash/src/main/swf/commonVideoViewContentSWF10.lzx?rev=1774125&r1=1774124&r2=1774125&view=diff
==============================================================================
--- 
openmeetings/application/branches/3.2.x/openmeetings-flash/src/main/swf/commonVideoViewContentSWF10.lzx
 (original)
+++ 
openmeetings/application/branches/3.2.x/openmeetings-flash/src/main/swf/commonVideoViewContentSWF10.lzx
 Wed Dec 14 05:14:19 2016
@@ -25,6 +25,12 @@
                <when property="$as3">
                        <passthrough>
                                import flash.external.ExternalInterface;
+                               import flash.media.Camera;
+                               import flash.media.Microphone;
+                               import flash.media.MicrophoneEnhancedMode;
+                               import flash.media.MicrophoneEnhancedOptions;
+                               import flash.media.SoundCodec;
+                               import flash.net.SharedObject;
                        </passthrough>
                </when>
        </switch>
@@ -40,14 +46,11 @@
                canvas.currentClient.canVideo = value;
        </method>
        
-       <method name="createEditRecordStream" args="isInterview, standalone, 
isSyncUpdate">
-               if($debug) Debug.info("createEditRecordStream,", isInterview, 
standalone, canvas.currentClient);
+       <method name="createEditRecordStream" args="isInterview">
+               if($debug) Debug.info("createEditRecordStream,", isInterview);
                new lz.editRecordStreamSWF10(canvas, {
                                isInterview: isInterview,
-                               standalone: standalone,
-                               isSyncUpdate: isSyncUpdate
                        });
-               return;
        </method>
 
        <method name="batchCreateVideo" args="selfStreamId, clients">
@@ -109,79 +112,79 @@
                Creates the video-view AND starts to stream/play the video
         -->
        <method name="createVideo" 
args="publicSID,displayName,broadcastId,avsettings,interviewPodId,object">
-               <![CDATA[
-                       if ($debug) Debug.info("createVideo, publicSID: 
",publicSID,"broadcastId: ",broadcastId,"AVsettings: ",avsettings);
-                       if ($debug) Debug.write(" createVideo ALL vars 
",object);
-                       var vidContainer = getVideoObjectByPublicSID(publicSID);
-                       if(vidContainer == null) {
-                               vidContainer = 
this.getNewVideoObjectByPos(publicSID);
-                               vidContainer.clientVars = object;
-                               setPartnerName(vidContainer, displayName);
-                               if (avsettings=="n"){
-                                       
vidContainer.setVideouserProfilePic(object);
-                                       
vidContainer.setAttribute("visibility","hidden");
-                               } else if (avsettings=="a"){
-                                       
vidContainer.setVideouserProfilePic(object);
-                                       if ($debug) Debug.warn("start play");
-                                       
vidContainer._chatvideoinner._videostream.playStream(broadcastId,-1);
-                                       vidContainer.setAttribute("visible", 
false);
-                               } else if (avsettings=="v" || avsettings=="av") 
{
-                                       //this means avsettings is either: "v" 
or "av"
-                                       
vidContainer.setDefaultVideoSize(object.VWidth,object.VHeight);
-                                       
vidContainer._chatvideoinner._videostream.playStream(broadcastId,-1);
-                                       
vidContainer.setAttribute("visibility","visible");
-                               } else {
-                                       //this means user did not select 
anything yet and streaming has not started
-                                       
vidContainer.setAttribute("visibility","hidden");
-                               }
-                               vidContainer.setAttribute("interviewPodId", 
interviewPodId);
-                               vidContainer.updateAVSettingsSymbol(object);
-                               if (object.micMuted) {
-                                       
vidContainer.setMicMuted(object.micMuted);
-                               }
+       <![CDATA[
+               if ($debug) Debug.info("createVideo, publicSID: 
",publicSID,"broadcastId: ",broadcastId,"AVsettings: ",avsettings);
+               if ($debug) Debug.write(" createVideo ALL vars ",object);
+               var vidContainer = getVideoObjectByPublicSID(publicSID);
+               if(vidContainer == null) {
+                       vidContainer = this.getNewVideoObjectByPos(publicSID);
+                       vidContainer.clientVars = object;
+                       setPartnerName(vidContainer, displayName);
+                       if (avsettings=="n"){
+                               vidContainer.setVideouserProfilePic(object);
+                               
vidContainer.setAttribute("visibility","hidden");
+                       } else if (avsettings=="a"){
+                               vidContainer.setVideouserProfilePic(object);
+                               if ($debug) Debug.warn("start play");
+                               
vidContainer._chatvideoinner._videostream.playStream(broadcastId,-1);
+                               vidContainer.setAttribute("visible", false);
+                       } else if (avsettings=="v" || avsettings=="av") {
+                               //this means avsettings is either: "v" or "av"
+                               
vidContainer.setDefaultVideoSize(object.VWidth,object.VHeight);
+                               
vidContainer._chatvideoinner._videostream.playStream(broadcastId,-1);
+                               
vidContainer.setAttribute("visibility","visible");
+                       } else {
+                               //this means user did not select anything yet 
and streaming has not started
+                               
vidContainer.setAttribute("visibility","hidden");
+                       }
+                       vidContainer.setAttribute("interviewPodId", 
interviewPodId);
+                       vidContainer.updateAVSettingsSymbol(object);
+                       if (object.micMuted) {
+                               vidContainer.setMicMuted(object.micMuted);
                        }
+               }
 
-                       if ($debug) Debug.write("Is interview ? 
",canvas.isInterview);
-                       if (canvas.isInterview && interviewPodId != null && 
interviewPodId > 0) {
-                               if ($debug) Debug.write("Is interview 
",interviewPodId,"x",canvas["interviewPod"+interviewPodId+"_x"]);
-                               vidContainer.setAttribute("interviewPodId", 
interviewPodId);
-                               
vidContainer.setAttribute("x",canvas["interviewPod"+interviewPodId+"_x"]);
-                               
vidContainer.setAttribute("y",canvas["interviewPod"+interviewPodId+"_y"]);
-                               vidContainer.setAttribute("width",322);
-                               vidContainer.setAttribute("height",281);
-                       }
-                       return;
-               ]]>
+               if ($debug) Debug.write("Is interview ? ",canvas.isInterview);
+               if (canvas.isInterview && interviewPodId != null && 
interviewPodId > 0) {
+                       if ($debug) Debug.write("Is interview 
",interviewPodId,"x",canvas["interviewPod"+interviewPodId+"_x"]);
+                       vidContainer.setAttribute("interviewPodId", 
interviewPodId);
+                       
vidContainer.setAttribute("x",canvas["interviewPod"+interviewPodId+"_x"]);
+                       
vidContainer.setAttribute("y",canvas["interviewPod"+interviewPodId+"_y"]);
+                       vidContainer.setAttribute("width",322);
+                       vidContainer.setAttribute("height",281);
+               }
+               return;
+       ]]>
        </method>
        
        <method name="getVideoObjectByPublicSID" args="publicSID">
-               <![CDATA[
-                       //if ($debug) Debug.write("getVideoObjectByPublicSid 
SEARCH: ", publicSID);
-                       for (var i = 0; i < this.subviews.length; ++i) {
-                               //if ($debug) 
Debug.write("this.subviews[i].publicSID ", this.subviews[i].publicSID);
-                               if (this.subviews[i].publicSID == publicSID) {
-                                       return this.subviews[i];
-                               }
+       <![CDATA[
+               //if ($debug) Debug.write("getVideoObjectByPublicSid SEARCH: ", 
publicSID);
+               for (var i = 0; i < this.subviews.length; ++i) {
+                       //if ($debug) Debug.write("this.subviews[i].publicSID 
", this.subviews[i].publicSID);
+                       if (this.subviews[i].publicSID == publicSID) {
+                               return this.subviews[i];
                        }
-                       if ($debug) Debug.warn(" - getVideoObjectByPublicSID - 
DID NOT FIND THE USER BY ", publicSID);
-                       return null;
-               ]]>
+               }
+               if ($debug) Debug.warn(" - getVideoObjectByPublicSID - DID NOT 
FIND THE USER BY ", publicSID);
+               return null;
+       ]]>
        </method>
 
        <method name="getNewVideoObjectByPos" args="publicSID">
-               <![CDATA[
-                       //Get a Free VideoView Slot
-                       var freePos = 
this.getVideoObjectFreePos(this.offsetLength,this.videoWidth,this.videoHeight);
+       <![CDATA[
+               //Get a Free VideoView Slot
+               var freePos = 
this.getVideoObjectFreePos(this.offsetLength,this.videoWidth,this.videoHeight);
 
-                       return new lz.videoObjectPlayBroadcast(this,{
-                                       publicSID:publicSID,
-                                       width:videoWidth,
-                                       height:videoHeight,
-                                       x:freePos[0],
-                                       y:freePos[1],
-                                       isInterview:canvas.isInterview
-                               });
-               ]]>
+               return new lz.videoObjectPlayBroadcast(this,{
+                               publicSID:publicSID,
+                               width:videoWidth,
+                               height:videoHeight,
+                               x:freePos[0],
+                               y:freePos[1],
+                               isInterview:canvas.isInterview
+                       });
+       ]]>
        </method>
 
        <method name="getNewVideoObject" args="publicSID">
@@ -195,15 +198,15 @@
        </method>
 
        <method name="getVideoObjectByInterviewPodId" args="interviewPodId">
-               <![CDATA[
-                       for (var i=0;i<this.subviews.length;i++){
-                               if 
(this.subviews[i].interviewPodId==interviewPodId){
-                                       return this.subviews[i];
-                               }
+       <![CDATA[
+               for (var i=0;i<this.subviews.length;i++){
+                       if (this.subviews[i].interviewPodId==interviewPodId){
+                               return this.subviews[i];
                        }
-                       if ($debug) Debug.warn(" - 
getVideoObjectByInterviewPodId - DID NOT FIND THE USER BY ",interviewPodId);
-                       return null;
-               ]]>
+               }
+               if ($debug) Debug.warn(" - getVideoObjectByInterviewPodId - DID 
NOT FIND THE USER BY ",interviewPodId);
+               return null;
+       ]]>
        </method>
 
        <method name="getVideoObjectCount">
@@ -219,51 +222,51 @@
        </method>
 
        <method name="getVideoObjectFreePos" 
args="offsetLength,videoWidth,videoHeight">
-               <![CDATA[
-                       var newx = 20;
-                       if (canvas.currentRoomObj.hideWhiteboard) {
-                               newx += SIDEPANEL_WIDTH;
-                       }
-                       var newy = 0;
-                       var posFound = false;
-                       if (offsetLength == undefined) {
-                               offsetLength=10;
-                       }
-                       while (!posFound) {
-                               posFound = true;
-                               for (var i=0;i<this.subviews.length;i++){
-                                       var subview = this.subviews[i];
-                                       var left = subview.x;
-                                       var right = subview.x + subview.width;
-                                       var top = subview.y;
-                                       var bottom = subview.y + subview.height;
-
-                                       if( !(newx > right
-                                               || (newx + videoWidth) < left
-                                               || newy > bottom
-                                               || (newy + videoHeight) < top ))
-                                       {
-                                               newx = right + offsetLength;
-                                               posFound = false;
-                                       }
-                                       if ((newx + videoWidth) >= 
canvas.width) {
-                                               newx = 20;
-                                               if 
(canvas.currentRoomObj.hideWhiteboard) {
-                                                       newx += SIDEPANEL_WIDTH;
-                                               }
-                                               newy += 10;
-                                               posFound = false;
+       <![CDATA[
+               var newx = 20;
+               if (canvas.currentRoomObj.hideWhiteboard) {
+                       newx += SIDEPANEL_WIDTH;
+               }
+               var newy = 0;
+               var posFound = false;
+               if (offsetLength == undefined) {
+                       offsetLength=10;
+               }
+               while (!posFound) {
+                       posFound = true;
+                       for (var i=0;i<this.subviews.length;i++){
+                               var subview = this.subviews[i];
+                               var left = subview.x;
+                               var right = subview.x + subview.width;
+                               var top = subview.y;
+                               var bottom = subview.y + subview.height;
+
+                               if( !(newx > right
+                                       || (newx + videoWidth) < left
+                                       || newy > bottom
+                                       || (newy + videoHeight) < top ))
+                               {
+                                       newx = right + offsetLength;
+                                       posFound = false;
+                               }
+                               if ((newx + videoWidth) >= canvas.width) {
+                                       newx = 20;
+                                       if 
(canvas.currentRoomObj.hideWhiteboard) {
+                                               newx += SIDEPANEL_WIDTH;
                                        }
+                                       newy += 10;
+                                       posFound = false;
                                }
                        }
+               }
 
-                       if ((newy + videoHeight) >= canvas.height) {
-                               newy = 0;
-                       }
+               if ((newy + videoHeight) >= canvas.height) {
+                       newy = 0;
+               }
 
-                       var result = [newx, newy];
-                       return result;
-               ]]>
+               var result = [newx, newy];
+               return result;
+       ]]>
        </method>
 
        <method name="disconnectclient" args="publicSID">
@@ -602,7 +605,7 @@
                }
        ]]>
        </method>
-   
+
        <!---
                Close a single screen sharing playback video
         --> 
@@ -616,7 +619,7 @@
                }
        ]]>
        </method>
-               
+
        <!---
           Closes all screen sharing playback videos, whiteboard videos, user 
videos 
           and closes the rtmp connection
@@ -671,10 +674,158 @@
                return testResult;
        ]]>
        </method>
-       
-       <!--
-               Container to hold all whiteboard videos
-       -->     
+
+       <method name="getMic" args="valMic">
+       <![CDATA[
+               if ($debug) Debug.write("Entering getMic ...", valMic);
+               if (valMic == null) {
+                       valMic = 0; //select first one by default
+               }
+               var _micro = canvas.echoPath == 0 ? 
Microphone.getMicrophone(valMic) : Microphone.getEnhancedMicrophone(valMic);
+               
+               if (_micro != null) {
+                       if (canvas.echoPath == 256) {
+                               var options:MicrophoneEnhancedOptions = new 
MicrophoneEnhancedOptions();
+                               options.mode = 
MicrophoneEnhancedMode.FULL_DUPLEX;
+                               options.echoPath = 256;
+                               options.nonLinearProcessing = true;
+                               _micro.enhancedOptions = options;
+                               if ($debug) Debug.write("echoPath set to 256");
+                               if ($debug) Debug.write(_micro.enhancedOptions);
+                       }
+                       _micro.codec = SoundCodec.NELLYMOSER;
+                       _micro.framesPerPacket = 1;
+                       _micro.setSilenceLevel(0, 2000);
+                       if ($debug) Debug.write("canvas.microphoneRateBest: ", 
canvas.microphoneRateBest);
+                       _micro.rate = (canvas.microphoneRateBest == 
'undefined') ? 22 : canvas.microphoneRateBest;
+                       _micro.gain = 50;
+                       // this has no effect if enhanced microphone is obtained
+                       //Microphone setUseEchoSupression(bool)
+                       var enableEchoSupression = !(canvas.echoSuppression === 
"false");
+                       if ($debug) Debug.write("canvas.echoSuppression: ", 
canvas.echoSuppression);
+                       _micro.setUseEchoSuppression(enableEchoSupression);
+               }
+               if ($debug) Debug.write("... getMic DONE", _micro);
+               return _micro;
+       ]]>
+       </method>
+       
+       <method name="getCam" args="valCam, videoview">
+       <![CDATA[
+               if ($debug) Debug.write("Entering getCam ...", valCam);
+               if (valCam == null) {
+                       valCam = 0; //select first one by default
+               }
+               var _camera = Camera.getCamera(valCam);
+               if (_camera != null) {
+                       if ($debug) Debug.write("videoview: ", videoview);
+                       
+                       if ($debug) Debug.write("_camera.setQuality BEST: ", 
canvas.isInterview, (canvas.bandwidthNeededBest * 2), canvas.camQualityBest);
+                       if (canvas.isInterview) {
+                               //we need a fixed frame rate for the videos to 
merge them later on
+                               _camera.setMode(videoview.width, 
videoview.height, 24, true);
+                               if ($debug) Debug.warn("IS INTERVIEW ");
+                               _camera.setQuality(0, 98);
+                       } else {
+                               if ($debug) Debug.write("_camera.setMode: ", 
videoview.width, videoview.height, canvas.framesPerSecond, true);
+                               _camera.setMode(videoview.width, 
videoview.height, canvas.framesPerSecond, true);
+                               if ($debug) Debug.warn("IS NO INTERVIEW ");
+                               _camera.setQuality(canvas.bandwidthNeededBest, 
canvas.camQualityBest);
+                       }
+               }
+               if ($debug) Debug.write("... getCam DONE", _camera);
+               return _camera;
+       ]]>
+       </method>
+
+       <method name="loadAVsettings">
+       <![CDATA[
+               var t:SharedObject = SharedObject.getLocal('userdata');
+               var g = t.data;
+               if ($debug) Debug.write("loadAVsettings: ", g["cam"], g["mic"]);
+
+               if(g["width"] > 0 && g["height"] > 0) {
+                       return g;
+               }
+               return null;
+       ]]>
+       </method>
+
+       <method name="getAvSetting" args="prop, g=null, def=null">
+               //Initialize and get eventually stored property
+               if (!g) {
+                       g = canvas.commonVideoViewContent.loadAVsettings();
+               }
+               var val = g != null ? g[prop] : null;
+               return val != null ? val : def;
+       </method>
+
+       <netRemoteCallHib name="restartAvBroadcast" funcname="getBroadCastId" 
remotecontext="$once{ canvas.thishib }">
+               <handler name="ondata" args="value">
+                       canvas.currentClient.broadCastID = value;
+                       parent.startAvBroadcast();
+               </handler>
+       </netRemoteCallHib>
+
+       <method name="startAvBroadcast">
+       <![CDATA[
+               var g = canvas.commonVideoViewContent.loadAVsettings();
+               var myvideocontainer = createVideoObject(canvas.publicSID, 
true, canvas.currentClient.interviewPodId, canvas.currentClient);
+               if ($debug) Debug.write("doStartConference::doninitalize");
+               var settings = getAvSetting('avstored', g, 'av');
+               if (!canvas.isInterview) {
+                       
myvideocontainer.setDefaultVideoSize(getAvSetting('width', g, 120), 
getAvSetting('height', g, 90));
+               }
+               
+               var videoview = myvideocontainer._chatvideoinner._videostream;
+               if ($debug) Debug.write("myvideocontainer: ", myvideocontainer);
+               myvideocontainer.setAttribute('isremote', false);
+               var _micro = getMic(getAvSetting('mic', g, 0));
+               var _camera = getCam(getAvSetting('cam', g, 0), videoview);
+               if ($debug) Debug.write(_camera , _micro, settings);
+               
+               if ($debug) Debug.write("BroadcastId: ", 
canvas.currentClient.broadCastID);
+               switch (settings){
+                       case "av":
+                               
videoview.broadcast(canvas.currentClient.broadCastID, _camera, _micro);
+                               myvideocontainer.setAttribute("visible", true);
+                               if(!canvas.isInterview) {
+                                       if (myvideocontainer.minimized) {
+                                               myvideocontainer.reminimize();
+                                       }
+                               }
+                               break;
+                       case "a":
+                               
videoview.broadcast(canvas.currentClient.broadCastID, null, _micro);
+                               myvideocontainer.setAttribute("visible", true);
+                               if(!canvas.isInterview) {
+                                       if (!myvideocontainer.minimized) {
+                                               myvideocontainer.minimize();
+                                       }
+                               }
+                               break;
+                       case "v":
+                               
videoview.broadcast(canvas.currentClient.broadCastID, _camera, null);
+                               myvideocontainer.setAttribute("visible", true);
+                               if(!canvas.isInterview) {
+                                       if (myvideocontainer.minimized) {
+                                               myvideocontainer.reminimize();
+                                       }
+                               }
+                               break;
+                       case "n":
+                               if ($debug) Debug.write("Do not Publish A/V");
+                               //Prevent from Hiding the Box in Event Modus
+                               if (canvas.thishib.modus == "conference") {
+                                       
myvideocontainer.setAttribute("visible", false);
+                               }
+                               break;
+                       default:
+                               if ($debug) Debug.warn("no valid device Setup 
chosen");
+                               break;
+               }
+       ]]>
+       </method>
 </class>
 
 </library>

Modified: 
openmeetings/application/branches/3.2.x/openmeetings-flash/src/main/swf/video/baseVideoObject.lzx
URL: 
http://svn.apache.org/viewvc/openmeetings/application/branches/3.2.x/openmeetings-flash/src/main/swf/video/baseVideoObject.lzx?rev=1774125&r1=1774124&r2=1774125&view=diff
==============================================================================
--- 
openmeetings/application/branches/3.2.x/openmeetings-flash/src/main/swf/video/baseVideoObject.lzx
 (original)
+++ 
openmeetings/application/branches/3.2.x/openmeetings-flash/src/main/swf/video/baseVideoObject.lzx
 Wed Dec 14 05:14:19 2016
@@ -405,29 +405,13 @@
                </view>
 
                <view name="_toolbar" x="${ parent.width-this.width-2 }" 
layout="axis:x;spacing:0" y="2">
-
                        <attribute name="isload" value="true" type="boolean" />
 
                        <miniIconsPresenter name="_resync" 
iconRessourceName="resyncuser_rsc">
                                <handler name="onclick">
                                        parent.parent.resetValues();
-                                       if(!this.parent.parent.isremote) {
-                                               if ($debug) 
Debug.write("editRecordStream ################# baseVideObject isInterview"
-                                                               
,this.parent.parent.isInterview,this.parent.parent.interviewPodId);
-                                               if 
(this.parent.parent.isInterview) {
-                                                       //TODO: fix it
-                                                       new 
lz.editRecordStreamSWF10(canvas.inner,{
-                                                               
name:"editRecordStream",
-                                                               
doDefaultAnimation:false,
-                                                               
isInterview:true,
-                                                               
interviewPodId:this.parent.parent.interviewPodId,
-                                                               
isSyncUpdate:true});
-                                               } else {
-                                                       new 
lz.editRecordStreamSWF10(canvas.inner,{
-                                                               
name:"editRecordStream",
-                                                               
isInterview:false,
-                                                               
isSyncUpdate:true});
-                                               }
+                                       if (!parent.parent.isremote) {
+                                               
canvas.commonVideoViewContent.restartAvBroadcast.doCall()
                                        }
                                </handler>
                                <labelTooltip name="_tip" labelid="540" />

Modified: 
openmeetings/application/branches/3.2.x/openmeetings-flash/src/main/swf/video/editRecordStreamSWF10.lzx
URL: 
http://svn.apache.org/viewvc/openmeetings/application/branches/3.2.x/openmeetings-flash/src/main/swf/video/editRecordStreamSWF10.lzx?rev=1774125&r1=1774124&r2=1774125&view=diff
==============================================================================
--- 
openmeetings/application/branches/3.2.x/openmeetings-flash/src/main/swf/video/editRecordStreamSWF10.lzx
 (original)
+++ 
openmeetings/application/branches/3.2.x/openmeetings-flash/src/main/swf/video/editRecordStreamSWF10.lzx
 Wed Dec 14 05:14:19 2016
@@ -40,26 +40,19 @@
                                import flash.events.StatusEvent;
                                import flash.media.Camera;
                                import flash.media.Microphone;
-                               import flash.media.MicrophoneEnhancedMode;
-                               import flash.media.MicrophoneEnhancedOptions;
                                import flash.net.SharedObject;
-                               import flash.media.SoundCodec;
                        </passthrough>
                </when>
        </switch>
 
-       <attribute name="myvideocontainer" value="null" />
-       <attribute name="standalone" value="false" type="boolean" />
        <attribute name="initY" value="40" type="number" />
        <attribute name="chosenCam" value="null" />
        <attribute name="chosenMic" value="null" />
        <attribute name="chosenSetting" value="null" />
-       <attribute name="currentClient" value="null" />
 
        <!---
                if true the user will see the dialog no matter if he has 
choosen "do not show again" or not
         -->
-       <attribute name="isSyncUpdate" value="false" type="boolean" />
        <attribute name="doDefaultAnimation" value="true" type="boolean" />
        <attribute name="cam_default_width" value="320" type="number" />
        <attribute name="cam_default_height" value="260" type="number" />
@@ -106,24 +99,16 @@
                
                this.counterDelegate = new LzDelegate(this, "count");
 
-               if ($debug) Debug.write("this.myvideocontainer 
",this.myvideocontainer);
                if ($debug) Debug.write("editrecordstream 
###################### ");
 
                initItems();
-               if (standalone) {
-                       if (this.doDefaultAnimation && !canvas.isInterview) {
-                               
this._chooseDeviceAnimation.setAttribute('started', true);
-                       } else {
-                               this.setAttribute("y", initY);
-                       }
-                       this.executeAttachCamera = true;
-                       this.attachCamera();
+               if (this.doDefaultAnimation && !canvas.isInterview) {
+                       this._chooseDeviceAnimation.setAttribute('started', 
true);
                } else {
-                       storeChosen();
-                       myvideocontainer = 
canvas.commonVideoViewContent.createVideoObject(canvas.publicSID, true, 
interviewPodId, canvas.currentClient);
-
-                       setUserAVSettings.doCall();
+                       this.setAttribute("y", initY);
                }
+               this.executeAttachCamera = true;
+               this.attachCamera();
                
                //TODO check this
                if (canvas.isInterview) {
@@ -142,56 +127,7 @@
        ]]>
        </handler>
 
-       <!-- 
-          If the remember check-box was true, this flag in the Flash Cookie 
(aka SharedObject)
-          is true and the box will close without asking for device settings.
-        -->
-       <method name="checkDeviceSettingsRememberStatus">
-       <![CDATA[
-               var t:SharedObject = SharedObject.getLocal('userdata');
-               var g = t.data;
-               var save = g["savecamdata"];
-               if ($debug) Debug.write("save: 
",save,g["cam"],g["mic"],this.isSyncUpdate);
-               //In case its an Audio-Only Room this box should not close 
automatically
-               if ($debug) Debug.write("canvas.currentRoomObj: ", 
canvas.currentRoomObj);
-               
-               //In case the user presses the Sync Button this box should
-               //not close automatically and do the user-prefered values
-               if(save && !this.isSyncUpdate && this.checkLocalDataComplete()) 
{
-                       return g;
-               }
-               return null;
-       ]]>
-       </method>
-       
-       <!-- 
-          Checks if all needed data in the shared object is available
-        -->
-       <method name="checkLocalDataComplete">
-               <![CDATA[
-                       var t:SharedObject = SharedObject.getLocal('userdata');
-                       var g = t.data;
-                       if (g["width"] > 0 && g["height"] > 0) {
-                               return true;
-                       }
-                       return false;
-               ]]>
-       </method>
-       
-       <netRemoteCallHib name="setUserAVSettings" funcname="setUserAVSettings" 
remotecontext="$once{ canvas.thishib }" >
-               <netparam><method name="getValue">return 
parent.parent.chosenSetting;</method></netparam>
-               <netparam><method name="getValue">return 
parent.parent.cam_default_width;</method></netparam>
-               <netparam><method name="getValue">return 
parent.parent.cam_default_height;</method></netparam>
-               <handler name="ondata" args="value">
-               <![CDATA[
-                       if ($debug) Debug.write("setUserAVSettings",value);
-                       parent.currentClient = value;
-                       parent.doStartConference();
-               ]]>
-               </handler>
-       </netRemoteCallHib>
-
-       <method name="storelocaldata">
+       <method name="storeAVsettings">
        <![CDATA[
                //if ($debug) Debug.write("sharedobject store::  [width, 
height] : [" + this.cam_default_width + ", " + this.cam_default_height + "]");
                var t:SharedObject = SharedObject.getLocal('userdata');
@@ -200,136 +136,12 @@
                g["cam"] = this.availableCams.getValue();
                g["mic"] = this.availableMics.getValue();
                g["avstored"] = this.availableSettings.getValue();
-               g["savecamdata"] = this.holddatainSO.getValue();
                g["width"] = this.cam_default_width;
                g["height"] = this.cam_default_height;
                t.flush();
        ]]>
        </method>
 
-       <method name="getMic" args="valMic">
-       <![CDATA[
-               if ($debug) Debug.write("Entering getMic ...", valMic);
-               var _micro = null;
-               if (valMic != null) {
-                       _micro = canvas.echoPath == 0 ? 
Microphone.getMicrophone(valMic) : Microphone.getEnhancedMicrophone(valMic);
-                       
-                       if (_micro != null && canvas.echoPath == 256) {
-                               var options:MicrophoneEnhancedOptions = new 
MicrophoneEnhancedOptions();
-                               options.mode = 
MicrophoneEnhancedMode.FULL_DUPLEX;
-                               options.echoPath = 256;
-                               options.nonLinearProcessing = true;
-                               _micro.enhancedOptions = options;
-                               if ($debug) Debug.write("echoPath set to 256");
-                               if ($debug) Debug.write(_micro.enhancedOptions);
-                       }
-                       
-                       if (_micro != null) {
-                               _micro.codec = SoundCodec.NELLYMOSER;
-                               _micro.framesPerPacket = 1;
-                               _micro.setSilenceLevel(0, 2000);
-                               if ($debug) 
Debug.write("canvas.microphoneRateBest: ",canvas.microphoneRateBest);
-                               _micro.rate = (canvas.microphoneRateBest == 
'undefined') ? 22 : canvas.microphoneRateBest;
-                               _micro.gain = 50;
-                               // this has no effect if enhanced microphone is 
obtained
-                               //Microphone setUseEchoSupression(bool)
-                               var enableEchoSupression = 
!(canvas.echoSuppression === "false");
-                               if ($debug) 
Debug.write("canvas.echoSuppression: ",canvas.echoSuppression);
-                               
_micro.setUseEchoSuppression(enableEchoSupression);
-                       }
-               }
-               if ($debug) Debug.write("... getMic DONE", _micro);
-               return _micro;
-       ]]>
-       </method>
-       
-       <method name="getCam" args="valCam,videoview">
-       <![CDATA[
-               if ($debug) Debug.write("Entering getCam ...", valCam);
-               var _camera = null;
-               if (valCam != null) {
-                       _camera = Camera.getCamera(valCam);
-               }
-               if (_camera != null) {
-                       if ($debug) Debug.write("videoview: ",videoview);
-                       
-                       if ($debug) Debug.write("_camera.setQuality BEST: ", 
canvas.isInterview, (canvas.bandwidthNeededBest*2), canvas.camQualityBest);
-                       if (canvas.isInterview) {
-                               //we need a fixed frame rate for the videos to 
merge them later on
-                               _camera.setMode(videoview.width, 
videoview.height, 24, true);
-                               if ($debug) Debug.warn("IS INTERVIEW ");
-                               _camera.setQuality(0, 98);
-                       } else {
-                               if ($debug) Debug.write("_camera.setMode: 
",videoview.width,videoview.height,canvas.framesPerSecond,true);
-                               _camera.setMode(videoview.width, 
videoview.height, canvas.framesPerSecond, true);
-                               if ($debug) Debug.warn("IS NO INTERVIEW ");
-                               _camera.setQuality(canvas.bandwidthNeededBest, 
canvas.camQualityBest);
-                       }
-               }
-               if ($debug) Debug.write("... getCam DONE", _camera);
-               return _camera;
-       ]]>
-       </method>
-       
-       <method name="doStartConference">
-       <![CDATA[
-               if ($debug) Debug.write("doninitalize");
-               var settings = this.chosenSetting;
-               if (!canvas.isInterview) {
-                       
this.myvideocontainer.setDefaultVideoSize(this.cam_default_width, 
this.cam_default_height);
-               }
-               
-               var videoview = 
this.myvideocontainer._chatvideoinner._videostream;
-               if ($debug) Debug.write("this.myvideocontainer: ", 
this.myvideocontainer);
-               this.myvideocontainer.setAttribute('isremote',false);
-               var _micro = this.getMic(this.chosenMic);
-               var _camera = this.getCam(this.chosenCam, videoview);
-               if ($debug) Debug.write(_camera , _micro, settings);
-               
-               if ($debug) Debug.write("BroadcastId: ", 
this.currentClient.broadCastID);
-               switch (settings){
-                       case "av":
-                               
videoview.broadcast(this.currentClient.broadCastID,_camera,_micro);
-                               this.myvideocontainer.setAttribute("visible", 
true);
-                               if(!canvas.isInterview) {
-                                       if (this.myvideocontainer.minimized) {
-                                               
this.myvideocontainer.reminimize();
-                                       }
-                               }
-                               break;
-                       case "a":
-                               
videoview.broadcast(this.currentClient.broadCastID,null,_micro);
-                               this.myvideocontainer.setAttribute("visible", 
true);
-                               if(!canvas.isInterview) {
-                                       if (!this.myvideocontainer.minimized) {
-                                               
this.myvideocontainer.minimize();
-                                       }
-                               }
-                               break;
-                       case "v":
-                               
videoview.broadcast(this.currentClient.broadCastID,_camera,null);
-                               this.myvideocontainer.setAttribute("visible", 
true);
-                               if(!canvas.isInterview) {
-                                       if (this.myvideocontainer.minimized) {
-                                               
this.myvideocontainer.reminimize();
-                                       }
-                               }
-                               break;
-                       case "n":
-                               if ($debug) Debug.write("Do not Publish A/V");
-                               //Prevent from Hiding the Box in Event Modus
-                               if (canvas.thishib.modus == "conference") {
-                                       
this.myvideocontainer.setAttribute("visibility","hidden");
-                               }
-                               break;
-                       default:
-                               if ($debug) Debug.warn("no valid device Setup 
chosen");
-                               break;
-               }
-               this.close();
-       ]]>
-       </method>
-       
        <method name="doStartRecording">
        <![CDATA[
                this._btnStartRecording.setAttribute("enabled",false);
@@ -340,8 +152,8 @@
                this.isRunning = true;
                
                var videoview = 
this._video.content._publisher._chatvideoinner._videostream;
-               var _micro = this.getMic(this.availableMics.getValue());
-               var _camera = this.getCam(this.availableCams.getValue(), 
videoview);
+               var _micro = 
canvas.commonVideoViewContent.getMic(this.availableMics.getValue());
+               var _camera = 
canvas.commonVideoViewContent.getCam(this.availableCams.getValue(), videoview);
                if ($debug) Debug.write(_camera, _micro);
                
                if ($debug && _camera != null) Debug.warn("_camera.muted ", 
_camera.muted);
@@ -435,17 +247,10 @@
        
        <attribute name="executeAttachCamera" value="false" type="boolean" />
 
-       <method name="getStoredProp" args="prop">
-               //Initialize and get eventually stored property
-               var t:SharedObject = SharedObject.getLocal('userdata');
-               var g = t.data;
-               return g != null ? "" + g[prop] : null;
-       </method>
-       
        <method name="fillDeviceList" args="list,combo,prop">
        <![CDATA[
                //Initialize and get eventually stored property
-               var dev = getStoredProp(prop);
+               var dev = canvas.commonVideoViewContent.getAvSetting(prop);
                
                //Get all availible devices
                var foundStoredDev = null;
@@ -500,13 +305,13 @@
                }
                availableSettings.addItem(canvas.getLabelName(451), "n");
                
-               var avstored = getStoredProp("avstored");
+               var avstored = 
canvas.commonVideoViewContent.getAvSetting("avstored");
                
-               if ((isSyncUpdate || standalone) && 
availableSettings.getItem(avstored) != null) {
+               if (availableSettings.getItem(avstored) != null) {
                        //get stored item
                        availableSettings.selectItem(avstored);
-               } else if 
(availableSettings.getItem(parent.currentClient.avsettings) != null) {
-                       
availableSettings.selectItem(parent.currentClient.avsettings);
+               } else if 
(availableSettings.getItem(canvas.currentClient.avsettings) != null) {
+                       
availableSettings.selectItem(canvas.currentClient.avsettings);
                } else {
                        availableSettings.selectItemAt(0);
                }
@@ -520,37 +325,30 @@
        </method>
        
        <method name="attachCamera">
-               <![CDATA[
-                       //if the user has configured this box to auto-close, do 
not try to
-                       //attach the cam to the preview (black) box
-                       var sharedData = 
this.checkDeviceSettingsRememberStatus();
-                       if(sharedData != null) {
-                               return;
-                       }
-                       
-                       //Don't execute before combobox items are not 
initialized
-                       if (!this.executeAttachCamera) {
-                               if ($debug) Debug.write("Return, 
executeAttachCamera is false");
-                               return;
-                       }
-               
-                       if (_video == undefined)  {
-                               if ($debug) Debug.write("Return, video video 
not yet ready");
-                               return;
-                       }
-                       _video.content._publisher.setAttribute("visible", true);
-                       _video.content._viewer.setAttribute("visible", false);
-                       var videoview = 
this._video.content._publisher._chatvideoinner._videostream;
-                       var _camera = getCam(availableCams.getValue(), 
videoview);
-                       if (_camera != null) {
-                               //stop will not call clear as there is no 
NetStream
-                               videoview._stop();
-                               videoview.clear();
-                               videoview.attachCamera(_camera);
-                       }
-               ]]>
+       <![CDATA[
+               //Don't execute before combobox items are not initialized
+               if (!this.executeAttachCamera) {
+                       if ($debug) Debug.write("Return, executeAttachCamera is 
false");
+                       return;
+               }
+
+               if (_video == undefined)  {
+                       if ($debug) Debug.write("Return, video not yet ready");
+                       return;
+               }
+               _video.content._publisher.setAttribute("visible", true);
+               _video.content._viewer.setAttribute("visible", false);
+               var videoview = 
this._video.content._publisher._chatvideoinner._videostream;
+               var _camera = 
canvas.commonVideoViewContent.getCam(availableCams.getValue(), videoview);
+               if (_camera != null) {
+                       //stop will not call clear as there is no NetStream
+                       videoview._stop();
+                       videoview.clear();
+                       videoview.attachCamera(_camera);
+               }
+       ]]>
        </method>
-       
+
        <method name="cleanVideos">
                if (_video == undefined) return;
                //make sure stop and clear is called, as the _stop method does 
not work for all
@@ -618,42 +416,33 @@
                ]]>
                </handler>
                <textlistitem 
datapath="myConfigSet:/config/availableCameraResolutions/resolution" >
-                       <switch>
-                               <when property="$as3">
-                                       <passthrough>
-                                               import flash.net.SharedObject;
-                                       </passthrough>
-                               </when>
-                       </switch>
                        <attribute name="cam_width" value="320" type="number" />
                        <attribute name="cam_height" value="240" type="number" 
/>
                        <handler name="ondata">
-                               <![CDATA[
-                                       // if ($debug) Debug.write("ondata ", 
this);
-                                       var type = 
this.datapath.xpathQuery('@type');
-                                       this.cam_width = 
Number(this.datapath.xpathQuery('@width'));
-                                       this.cam_height = 
Number(this.datapath.xpathQuery('@height'));
-                                       
this.setAttribute("text",""+this.cam_width+"x"+this.cam_height+" ["+type+"]");
-                                       var isDefault = 
this.datapath.xpathQuery('@isDefault') == "true";
-                                       
-                                       var t:SharedObject = 
SharedObject.getLocal('userdata');
-                                       var g = t.data;
-                                       var width = g["width"];
-                                       var height = g["height"];
-                                       if (width!=null && width > 0 && 
height!=null && height>0) {
-                                               if (width == this.cam_width && 
height == this.cam_height) {
-                                                       
parent.selectItemAt(parent.counter);
-                                                       
parent.onselect.sendEvent(this);
-                                               }
-                                       } else {
-                                               if (isDefault) {
-                                                       if ($debug) 
Debug.write("Found default one ",type);
-                                                       
parent.selectItemAt(parent.counter);
-                                                       
parent.onselect.sendEvent(this);
-                                               }
+                       <![CDATA[
+                               // if ($debug) Debug.write("ondata ", this);
+                               var type = this.datapath.xpathQuery('@type');
+                               this.cam_width = 
Number(this.datapath.xpathQuery('@width'));
+                               this.cam_height = 
Number(this.datapath.xpathQuery('@height'));
+                               this.setAttribute("text", "" + this.cam_width + 
"x" + this.cam_height + " [" + type + "]");
+                               var isDefault = 
this.datapath.xpathQuery('@isDefault') == "true";
+                               
+                               var width = 
canvas.commonVideoViewContent.getAvSetting("width");
+                               var height = 
canvas.commonVideoViewContent.getAvSetting("height");
+                               if (width != null && height != null) {
+                                       if (width == this.cam_width && height 
== this.cam_height) {
+                                               
parent.selectItemAt(parent.counter);
+                                               parent.onselect.sendEvent(this);
                                        }
-                                       parent.counter += 1;
-                               ]]>
+                               } else {
+                                       if (isDefault) {
+                                               if ($debug) Debug.write("Found 
default one ",type);
+                                               
parent.selectItemAt(parent.counter);
+                                               parent.onselect.sendEvent(this);
+                                       }
+                               }
+                               parent.counter += 1;
+                       ]]>
                        </handler>
                </textlistitem>
        </resetCombobox>
@@ -706,8 +495,8 @@
        </simpleLabelButton>
 
        <view name="_level_meter" x="340" y="${ parent.height-190 }" 
width="240" height="20" clip="true" bgcolor="0x000000">
-                <!--- Level delegate, used to track level changes. 
-                         @keywords private -->
+                <!--- Level delegate, used to track level changes.
+                       @keywords private -->
                <attribute name="_leveldel" value="$once{new LzDelegate(this, 
'_updateLevel')}"/>
                
                <method name="_updateLevel" args="no">
@@ -747,43 +536,24 @@
        <labelText fontstyle="bold" labelid="765" x="39" y="${ 
parent.height-100 }"
                        width="${ parent.width-50 }" multiline="true" />
 
-       <!-- Remember Me -->
-       <labelCheckbox name="holddatainSO" labelid="762" x="10" y="${ 
parent.height-20 }" visible="${ !parent.standalone }" >
-               <switch>
-                       <when property="$as3">
-                               <passthrough>
-                                       import flash.net.SharedObject;
-                               </passthrough>
-                       </when>
-               </switch>
-               <handler name="oninit">
-                       var t:SharedObject = SharedObject.getLocal('userdata');
-                       var g = t.data;
-                       var save = g["savecamdata"];
-                       if ($debug) Debug.write("savecamdata save: ",save);
-                       if(save) this.setValue(true);
-               </handler>
-       </labelCheckbox>
-
        <method name="storeChosen">
                chosenCam = availableCams.getValue();
                chosenMic = availableMics.getValue();
                chosenSetting = availableSettings.getValue();
        </method>
 
-       <simpleLabelButton fontsize="11" visible="${ !parent.standalone 
&amp;&amp; canvas.isInterview }" labelid="918" x="${ parent.width-110 }"
-                       y="${ parent.height-50 }" width="100">
+       <simpleLabelButton fontsize="11" labelid="918" x="${ parent.width-280 
}" y="${ parent.height-50 }" width="100">
                <handler name="onclick">
                        parent.cleanVideos();
                        parent.close();
                </handler>
        </simpleLabelButton>
 
-       <simpleLabelButton fontsize="11" visible="${ parent.standalone }" 
labelid="144" width="160" x="${ parent.width-170 }" 
+       <simpleLabelButton fontsize="11" labelid="144" width="160" x="${ 
parent.width-170 }" 
                        y="${ parent.height-50 }" height="28">
                <handler name="onclick">
                        parent.cleanVideos();
-                       parent.storelocaldata();
+                       parent.storeAVsettings();
                        parent.storeChosen();
                        parent.close();
                </handler>

Modified: 
openmeetings/application/branches/3.2.x/openmeetings-flash/src/main/swf/video/videoUserProfilePicSWF10.lzx
URL: 
http://svn.apache.org/viewvc/openmeetings/application/branches/3.2.x/openmeetings-flash/src/main/swf/video/videoUserProfilePicSWF10.lzx?rev=1774125&r1=1774124&r2=1774125&view=diff
==============================================================================
--- 
openmeetings/application/branches/3.2.x/openmeetings-flash/src/main/swf/video/videoUserProfilePicSWF10.lzx
 (original)
+++ 
openmeetings/application/branches/3.2.x/openmeetings-flash/src/main/swf/video/videoUserProfilePicSWF10.lzx
 Wed Dec 14 05:14:19 2016
@@ -26,7 +26,7 @@
                
        <handler name="oninit">
        <![CDATA[
-               if ($debug) Debug.write("setUserAVSettings", this);
+               if ($debug) Debug.write("videoUserProfilePicSWF10::oninit", 
this);
                this._userpic.setAttribute('src', 
canvas.getPictureUrl(value.userId, value.picture_uri));
        ]]>
        </handler>      

Modified: 
openmeetings/application/trunk/openmeetings-core/src/main/java/org/apache/openmeetings/core/remote/red5/ScopeApplicationAdapter.java
URL: 
http://svn.apache.org/viewvc/openmeetings/application/trunk/openmeetings-core/src/main/java/org/apache/openmeetings/core/remote/red5/ScopeApplicationAdapter.java?rev=1774125&r1=1774124&r2=1774125&view=diff
==============================================================================
--- 
openmeetings/application/trunk/openmeetings-core/src/main/java/org/apache/openmeetings/core/remote/red5/ScopeApplicationAdapter.java
 (original)
+++ 
openmeetings/application/trunk/openmeetings-core/src/main/java/org/apache/openmeetings/core/remote/red5/ScopeApplicationAdapter.java
 Wed Dec 14 05:14:19 2016
@@ -1530,31 +1530,6 @@ public class ScopeApplicationAdapter ext
                return 1;
        }
 
-       public int sendVarsModeratorGeneral(Object vars) {
-               log.debug("*..*sendVars: " + vars);
-               try {
-                       IConnection current = Red5.getConnectionLocal();
-                       Client currentClient = 
sessionManager.getClientByStreamId(current.getClient().getId(), null);
-
-                       log.debug("***** id: " + currentClient.getStreamid());
-
-                       boolean ismod = currentClient.getIsMod();
-
-                       if (ismod) {
-                               log.debug("CurrentScope :" + 
current.getScope().getName());
-                               // Send to all Clients of the same Scope
-                               
sendMessageToCurrentScope("sendVarsToModeratorGeneral", vars, false);
-                               return 1;
-                       } else {
-                               // log.debug("*..*you are not allowed to send: 
"+ismod);
-                               return -1;
-                       }
-               } catch (Exception err) {
-                       log.error("[sendVarsModeratorGeneral]", err);
-               }
-               return -1;
-       }
-
        public int sendMessage(Object newMessage) {
                sendMessageToCurrentScope("sendVarsToMessage", newMessage, 
false);
                return 1;


Reply via email to