Author: solomax
Date: Thu Feb 21 09:17:26 2013
New Revision: 1448558

URL: http://svn.apache.org/r1448558
Log:
SIP: Mute/unmute is now works as expected;
        code simplified;

Modified:
    
openmeetings/trunk/singlewebapp/WebContent/swf10/base/remote/baseVideoStream.lzx
    
openmeetings/trunk/singlewebapp/WebContent/swf10/commonVideoViewContentSWF10.lzx
    openmeetings/trunk/singlewebapp/WebContent/swf10/video/baseVideoObject.lzx
    
openmeetings/trunk/singlewebapp/src/org/apache/openmeetings/remote/red5/ScopeApplicationAdapter.java

Modified: 
openmeetings/trunk/singlewebapp/WebContent/swf10/base/remote/baseVideoStream.lzx
URL: 
http://svn.apache.org/viewvc/openmeetings/trunk/singlewebapp/WebContent/swf10/base/remote/baseVideoStream.lzx?rev=1448558&r1=1448557&r2=1448558&view=diff
==============================================================================
--- 
openmeetings/trunk/singlewebapp/WebContent/swf10/base/remote/baseVideoStream.lzx
 (original)
+++ 
openmeetings/trunk/singlewebapp/WebContent/swf10/base/remote/baseVideoStream.lzx
 Thu Feb 21 09:17:26 2013
@@ -313,28 +313,30 @@
        <!--- sets the Volume of the VideoStream
                @param number volume Number between 0 and 100
         -->
-    <method name="setSoundVolume" args="volume">
-        //this.soundRef.setVolume(volume);
-        if (this._ns!=null){
-            this._ns.soundTransform = new SoundTransform(volume/100.0);
-        }
-    </method>
+       <method name="setSoundVolume" args="volume">
+               //if ($debug) Debug.write(":: setSoundVolume ", 
parent.parent.publicSID);
+               //this.soundRef.setVolume(volume);
+               if (this._ns!=null){
+                       this._ns.soundTransform = new 
SoundTransform(volume/100.0);
+               }
+       </method>
 
-    <method name="muteMicro" args="mute">
-        if(this.micro != null) {
-            if(mute) {
-               if (this.micro.gain == 0) {
-                       return;
-               }
-               if ($debug) Debug.write("Make Gain mute again from 
",this.micro.gain);
-                this.setAttribute('micGain', this.micro.gain);
-                this.micro.gain = 0;
-            } else {
-               if ($debug) Debug.write("Make Gain loud again to 
",this.micGain);
-                this.micro.gain = this.micGain;
-            }
-        }
-    </method>
+       <method name="muteMicro" args="mute">
+               if ($debug) Debug.write(":: muteMicro ", mute, 
parent.parent.publicSID);
+               if(this.micro != null) {
+                       if(mute) {
+                               if (this.micro.gain == 0) {
+                                       return;
+                               }
+                               if ($debug) Debug.write("Make Gain mute again 
from ",this.micro.gain);
+                               this.setAttribute('micGain', this.micro.gain);
+                               this.micro.gain = 0;
+                       } else {
+                               if ($debug) Debug.write("Make Gain loud again 
to ",this.micGain);
+                               this.micro.gain = this.micGain;
+                       }
+               }
+       </method>
     
     <!---
         pause or resumes the NetStream

Modified: 
openmeetings/trunk/singlewebapp/WebContent/swf10/commonVideoViewContentSWF10.lzx
URL: 
http://svn.apache.org/viewvc/openmeetings/trunk/singlewebapp/WebContent/swf10/commonVideoViewContentSWF10.lzx?rev=1448558&r1=1448557&r2=1448558&view=diff
==============================================================================
--- 
openmeetings/trunk/singlewebapp/WebContent/swf10/commonVideoViewContentSWF10.lzx
 (original)
+++ 
openmeetings/trunk/singlewebapp/WebContent/swf10/commonVideoViewContentSWF10.lzx
 Thu Feb 21 09:17:26 2013
@@ -336,14 +336,14 @@
         return;
     ]]></method>
 
-    <method name="updateMuteStatusVideoView" args="roomClient">
-        <![CDATA[
-            for (var i=0;i<this.subviews.length;i++){
-                this.subviews[i].muteMicrophone(roomClient);
-               }
-               return;
-        ]]>
-    </method>
+       <method name="updateMuteStatusVideoView" args="roomClient">
+       <![CDATA[
+               var obj = this.getVideoObjectByPublicSID(roomClient.publicSID);
+               if (obj != null) {
+                       obj.muteMicrophone(roomClient);
+               }
+       ]]>
+       </method>
 
     <method name="ismoderatorChanged" args="m">
         canvas.setAttribute("ismoderator", m);
@@ -496,6 +496,7 @@
        <method name="updateFirstLastName" args="publicSID,first,last">
                var v = getVideoObjectByPublicSID(publicSID);
                if (v != null) {
+                       if ($debug) Debug.write("!!!!!!! updating 
FirstLastName",publicSID,first,last);
                        v.setAttribute('chatpartnername', first + ' ' + last);
                }
        </method>

Modified: 
openmeetings/trunk/singlewebapp/WebContent/swf10/video/baseVideoObject.lzx
URL: 
http://svn.apache.org/viewvc/openmeetings/trunk/singlewebapp/WebContent/swf10/video/baseVideoObject.lzx?rev=1448558&r1=1448557&r2=1448558&view=diff
==============================================================================
--- openmeetings/trunk/singlewebapp/WebContent/swf10/video/baseVideoObject.lzx 
(original)
+++ openmeetings/trunk/singlewebapp/WebContent/swf10/video/baseVideoObject.lzx 
Thu Feb 21 09:17:26 2013
@@ -1,96 +1,82 @@
 <?xml version="1.0" encoding="UTF-8" ?>
-<!--
-  Licensed to the Apache Software Foundation (ASF) under one
-  or more contributor license agreements.  See the NOTICE file
-  distributed with this work for additional information
-  regarding copyright ownership.  The ASF licenses this file
-  to you under the Apache License, Version 2.0 (the
-  "License"); you may not use this file except in compliance
-  with the License.  You may obtain a copy of the License at
-  
-      http://www.apache.org/licenses/LICENSE-2.0
-         
-  Unless required by applicable law or agreed to in writing,
-  software distributed under the License is distributed on an
-  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-  KIND, either express or implied.  See the License for the
-  specific language governing permissions and limitations
-  under the License.
-  
--->
+<!-- Licensed to the Apache Software Foundation (ASF) under one or more 
contributor license agreements. See the NOTICE file 
+       distributed with this work for additional information regarding 
copyright ownership. The ASF licenses this file to you under 
+       the Apache License, Version 2.0 (the "License"); you may not use this 
file except in compliance with the License. You may 
+       obtain a copy of the License at 
http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or 
agreed to 
+       in writing, software distributed under the License is distributed on an 
"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF 
+       ANY KIND, either express or implied. See the License for the specific 
language governing permissions and limitations under 
+       the License. -->
 <library>
 
 
-<!---
-       Base container for a client, can be either:
-       a remote-video (subscribing/playing a video)
-       or a self-video (broadcasting a cam/mic)
- -->
-<class name="baseVideoObject" extends="view" bgcolor="0x000000" width="122" 
height="101">
-
-       <switch>
-               <when property="$as3">
-                       <passthrough>
-                               import flash.filters.DropShadowFilter;
-                               import flash.media.*
-                               import flash.net.SharedObject;
-                       </passthrough>
-               </when>
-       </switch>
-        
-       <!--- @keywords private -->
-       <attribute name="chatpartnername" value="" type="string" />
-       <!--- @keywords private -->
-       <attribute name="showUserProfilePic" type="boolean" value="false" />
-       
-       <!--- color of this user, this is the color the user will also use for 
his chat-color -->
-       <attribute name="usercolor" value="0" type="number" />
-               
-       <!--- publicSID is a hash-value to identify a user -->
-       <attribute name="publicSID" value="" type="string" />
+       <!--- Base container for a client, can be either: a remote-video 
(subscribing/playing a video) or a self-video (broadcasting 
+               a cam/mic) -->
+       <class name="baseVideoObject" extends="view" bgcolor="0x000000" 
width="122" height="101">
+
+               <switch>
+                       <when property="$as3">
+                               <passthrough>
+                                       import flash.filters.DropShadowFilter;
+                                       import flash.media.*
+                                       import flash.net.SharedObject;
+                               </passthrough>
+                       </when>
+               </switch>
+
+               <!--- @keywords private -->
+               <attribute name="chatpartnername" value="" type="string" />
+               <!--- @keywords private -->
+               <attribute name="showUserProfilePic" type="boolean" 
value="false" />
+
+               <!--- color of this user, this is the color the user will also 
use for his chat-color -->
+               <attribute name="usercolor" value="0" type="number" />
+
+               <!--- publicSID is a hash-value to identify a user -->
+               <attribute name="publicSID" value="" type="string" />
+
+               <!--- micMuted indicates if the microphone is currently turned 
sound or gain to 0 -->
+               <attribute name="micMuted" value="false" type="boolean" />
+
+               <!--- @keywords private -->
+               <attribute name="isremote" value="true" type="boolean" />
+
+               <!--- @keywords private -->
+               <attribute name="clientVars" value="null" />
+
+               <!--- @keywords private -->
+               <attribute name="isResizing" value="false" type="boolean" />
+
+               <!--- @keywords private -->
+               <attribute name="isInterview" value="false" type="boolean" />
+
+               <attribute name="respectRatio" value="true" type="boolean" />
 
-       <!--- micMuted indicates if the microphone is currently turned sound or 
gain to 0 -->
-       <attribute name="micMuted" value="false" type="boolean" />
-       
-       <!--- @keywords private -->
-       <attribute name="isremote" value="true" type="boolean" />
-       
-       <!--- @keywords private -->
-       <attribute name="clientVars" value="null" />
-    
-    <!--- @keywords private -->
-    <attribute name="isResizing" value="false" type="boolean" />
-    
-    <!--- @keywords private -->
-    <attribute name="isInterview" value="false" type="boolean" />
-    
-    <attribute name="respectRatio" value="true" type="boolean" />
-    
-    <attribute name="minimized" value="false" type="boolean" />
-    
-    <attribute name="hidebyAudioOnly" value="false" type="boolean" />
-    
-    <attribute name="custom" value="false" type="boolean" />
-    
-    <attribute name="initH" value="40" type="number" />
-    <attribute name="initW" value="40" type="number" />
-
-    <attribute name="isShowMicMute" value="false" type="boolean"/>
-
-    <attribute name="isMutedByModerator" value="false" type="boolean"/>
-    
-    <attribute name="isMicrophonesRoom" value="false" type="boolean"/>
-
-    <attribute name="lastPositiveVolume" type="number" value="50" />
-
-    <!-- Initial stream ratio: width / height -->
-    <attribute name="initRatio" type="number" value="null" />
-       
-       <handler name="onisremote" args="r">
-               this.isremote = r;
-       </handler>
-    
-    <handler name="oninit">
+               <attribute name="minimized" value="false" type="boolean" />
+
+               <attribute name="hidebyAudioOnly" value="false" type="boolean" 
/>
+
+               <attribute name="custom" value="false" type="boolean" />
+
+               <attribute name="initH" value="40" type="number" />
+               <attribute name="initW" value="40" type="number" />
+
+               <attribute name="isShowMicMute" value="false" type="boolean" />
+
+               <attribute name="isMutedByModerator" value="false" 
type="boolean" />
+
+               <attribute name="isMicrophonesRoom" value="false" 
type="boolean" />
+
+               <attribute name="lastPositiveVolume" type="number" value="50" />
+
+               <!-- Initial stream ratio: width / height -->
+               <attribute name="initRatio" type="number" value="null" />
+               <attribute name="initialHeight" value="$once{ this.height }" 
type="number" />
+
+               <handler name="onisremote" args="r">
+                       this.isremote = r;
+               </handler>
+
+               <handler name="oninit">
         <![CDATA[
             this.clientVars = new Array();
             this.clientVars['User']='No User Connected';
@@ -110,14 +96,7 @@
                 this._loudness.setAttribute("visibility","hidden");
                 this._innertop.setAttribute("visibility","hidden");
                 this._innerbottom.setAttribute("visibility","hidden");
-                
-                //return;
             }
-            
-            //var prop1 = [this, "width"];
-            //var prop2 = [this, "height"];
-            //this.applyConstraintMethod("setItemContraintsWidth", prop1);
-            //this.applyConstraintMethod("setItemContraintsHeight", prop2);
             this.setShadow();
             
             if (this.publicSID == canvas.publicSID) {
@@ -132,75 +111,58 @@
             } else {
                 this._innerbottom.setAttribute("visibility", "hidden");
             }
-            
         ]]>
-    
-    </handler>
-       
-       <handler name="ony">
+               </handler>
+
+               <handler name="ony">
                <![CDATA[
-                   if (this.isInterview) {
-                return;
-            }
-            if (this.custom) {
-                return;
-            }
-                       if (canvas.currentRoomObject.hideWhiteboard) {
+                   if (this.isInterview || this.custom || 
canvas.currentRoomObject.hideWhiteboard) {
                 return;
             }
             var bounds = this.getBounds();
             var parentBounds = canvas.getBounds();
-            if ( bounds.y < 0 )
-            {
+            if (bounds.y < 0) {
                 this.setAttribute('y',0);
             }
-            if ( bounds.y > ( parentBounds.height - bounds.height ) )
-            {           
+            if (bounds.y > (parentBounds.height - bounds.height)) {           
                 this.setAttribute('y', parentBounds.height - bounds.height );
             }
         ]]>
-    </handler>
+               </handler>
 
-       <handler name="onx">
+               <handler name="onx">
                <![CDATA[
-               
-            if (this.isInterview) {
+            if (this.isInterview || this.custom) {
                 return;
             }  
-            
-            if (this.custom) {
-                return;
-            }
                
                        var bounds = this.getBounds();
             var parentBounds = canvas.getBounds();
-            if ( bounds.x < 0 )
-            {
+            if (bounds.x < 0) {
                 this.setAttribute('x',0);
             }
             
-            if ( bounds.x > ( parentBounds.width - bounds.width ) )
-            {
+            if (bounds.x > (parentBounds.width - bounds.width)) {
                 this.setAttribute('x', parentBounds.width - bounds.width );
             }
         ]]>
-    </handler>
-       
-    <method name="setShadow">
-        <![CDATA[
-        if (this.isinited){
-            this.normalMC = this.getDisplayObject();
-            //if($debug) Debug.write(this.normalMC);
-            //if($debug) Debug.write("this.normalMC: ",this.normalMC);
-            //if($debug) Debug.write("this: ",this);
-            this.displacementMap = new flash.filters.DropShadowFilter();
-            this.normalMC.filters = [this.displacementMap];
-        }
-        ]]>              
-    </method>   
-        
-    <!-- respect ratio and keep minimum width / height -->
-    <method name="setItemContraintsWidth" args="unused">
+               </handler>
+
+               <method name="setShadow">
+        <![CDATA[
+               if (this.isinited){
+                   this.normalMC = this.getDisplayObject();
+                   //if($debug) Debug.write(this.normalMC);
+                   //if($debug) Debug.write("this.normalMC: ",this.normalMC);
+                   //if($debug) Debug.write("this: ",this);
+                   this.displacementMap = new flash.filters.DropShadowFilter();
+                   this.normalMC.filters = [this.displacementMap];
+               }
+        ]]>
+               </method>
+
+               <!-- respect ratio and keep minimum width / height -->
+               <method name="setItemContraintsWidth" args="unused">
         <![CDATA[
             if (!this.respectRatio) {
                 return;
@@ -212,9 +174,9 @@
 
             this.setAttribute("height",h);
         ]]>
-    </method>
+               </method>
 
-    <method name="setItemContraintsHeight" args="unused">
+               <method name="setItemContraintsHeight" args="unused">
         <![CDATA[
             if (!this.respectRatio) {
                 return;
@@ -226,90 +188,80 @@
 
             this.setAttribute("width",w);
         ]]>
-    </method>
-       
-       <method name="updateAVSettingsSymbol" args="rcl">
-               //FIXME: Set a Symbol wether this Client is 
Audio(only)/Video(only), both or Profile Picture 
-               if ($debug) Debug.warn("updateAVSettingsSymbol TODO ",rcl);
-       </method>
-
-
-    
-    <method name="doResize" args="bool">
-        if ($debug) Debug.write("doResize ",bool);
-        if(bool) {
-            dragHelper.create();
-        } else {
-            dragHelper.remove();
-        }
-        if (this.isInterview) {
-            return;
-        }   
-        
-        if (this.custom) {
-                return;
-        }
-        
-        if (bool) {
-            this.isResizing = true;
-            this.rs.apply();
-        } else {
-            this.isResizing = false;
-            this.rs.remove();
-        }
-    </method>
-    
-    <!--- resets all values and stops the streaming -->
-    <method name="resetValues">
-      <![CDATA[
-       this.clientVars=null;
-       if (this.showUserProfilePic && !this.isremote){
-               this._chatvideoinner.userProfilePic.destroy();
-               this.showUserProfilePic = false;
-       }
-       if ($debug) Debug.write("resetValues: ",this.isremote);
-       if (this.isremote){
-               this._chatvideoinner._videostream.restart();
-       } else {
-               this._chatvideoinner._videostream._stop();
-       }
-     ]]>
-    </method>
-    <method name="setVideouserProfilePic" args="value">
-       if ($debug) Debug.write("### setVideouserProfilePic ",value);
-       this.deleteVideoConfProfilePic(value);
-       new 
lz.videoUserProfilePicSWF10(this._chatvideoinner,{name:'userProfilePic',value:value});
-       this.showUserProfilePic = true;
-    </method>    
-    <method name="deleteVideoConfProfilePic" args="value">
-       if ($debug) Debug.write("### deleteVideoConfProfilePic ",value);
-        if ($debug) Debug.write("delete ",this.showUserProfilePic);
-       if (this.showUserProfilePic){
-               this._chatvideoinner.userProfilePic.destroy();
-               this.showUserProfilePic = false;
-       }
-    </method>    
-    
-        <!--- @keywords private  -->
-    <method name="_startDragState" args="obj">
-       
-        if (this.isInterview) {
-            return;
-        }      
-        
-        if (this.custom) {
-            return;
-        }
-
-        dragHelper.create();
-
-        this.bringToFront();
-        parent.bringToFront();
-        this.dragger.apply();
-    </method> 
-    
-        <!--- @keywords private  -->
-    <method name="_removeDragState" args="obj">
+               </method>
+
+               <method name="updateAVSettingsSymbol" args="rcl">
+                       //FIXME: Set a Symbol wether this Client is 
Audio(only)/Video(only), both or Profile Picture
+                       if ($debug) Debug.warn("updateAVSettingsSymbol TODO 
",rcl);
+               </method>
+
+               <method name="doResize" args="bool">
+                       if ($debug) Debug.write("doResize",bool);
+                       if(bool) {
+                               dragHelper.create();
+                       } else {
+                               dragHelper.remove();
+                       }
+                       if (this.isInterview || this.custom) {
+                               return;
+                       }
+
+                       if (bool) {
+                               this.isResizing = true;
+                               this.rs.apply();
+                       } else {
+                               this.isResizing = false;
+                               this.rs.remove();
+                       }
+               </method>
+
+               <!--- resets all values and stops the streaming -->
+               <method name="resetValues">
+               <![CDATA[
+               this.clientVars=null;
+               if (this.showUserProfilePic && !this.isremote){
+                       this._chatvideoinner.userProfilePic.destroy();
+                       this.showUserProfilePic = false;
+               }
+               if ($debug) Debug.write("resetValues: ",this.isremote);
+               if (this.isremote){
+                       this._chatvideoinner._videostream.restart();
+               } else {
+                       this._chatvideoinner._videostream._stop();
+               }
+               ]]>
+               </method>
+               <method name="setVideouserProfilePic" args="value">
+                       if ($debug)
+                       Debug.write("### setVideouserProfilePic ",value);
+                       this.deleteVideoConfProfilePic(value);
+                       new 
lz.videoUserProfilePicSWF10(this._chatvideoinner,{name:'userProfilePic',value:value});
+                       this.showUserProfilePic = true;
+               </method>
+               <method name="deleteVideoConfProfilePic" args="value">
+                       if ($debug) Debug.write("### deleteVideoConfProfilePic 
",value);
+                       if ($debug) Debug.write("delete 
",this.showUserProfilePic);
+                       if (this.showUserProfilePic) {
+                               this._chatvideoinner.userProfilePic.destroy();
+                               this.showUserProfilePic = false;
+                       }
+               </method>
+
+               <!--- @keywords private -->
+               <method name="_startDragState" args="obj">
+                       if (this.isInterview || this.custom) {
+                               return;
+                       }
+
+                       dragHelper.create();
+
+                       this.bringToFront();
+                       parent.bringToFront();
+                       this.dragger.apply();
+               </method>
+
+               <!--- @keywords private -->
+               <method name="_removeDragState" args="obj">
        <![CDATA[
                lz.Cursor.unlock();
                
@@ -328,19 +280,13 @@
                if (this.y+this.height > parent.height) {
                        this.setAttribute("y",parent.height - this.height - 20);
                }
-
                dragHelper.remove();
-
                this.dragger.remove();
-        
         ]]>
-    </method>
-    
-    <attribute name="initialHeight" value="$once{ this.height }" type="number" 
/>
-    
-    <method name="minimize">
+               </method>
+
+               <method name="minimize">
         <![CDATA[
-        
             this.respectRatio = false;
         
             this.setAttribute("minimized",true);
@@ -364,9 +310,9 @@
             this._minimizeZoom.setAttribute("to",20);
             this._minimizeZoom.setAttribute('started', true);
         ]]>
-    </method>
-    
-    <method name="reminimize">
+               </method>
+
+               <method name="reminimize">
         <![CDATA[
             this.setAttribute("minimized",false);
             
@@ -380,12 +326,11 @@
             this._minimizeZoom.setAttribute("to",this.initialHeight);
             this._minimizeZoom.setAttribute('started', true);
         ]]>
-    </method>    
-    
-    <method name="reminimizeComplete">
+               </method>
+
+               <method name="reminimizeComplete">
         <![CDATA[
             if (!this.minimized) {
-                
                 for (var eg in this.subviews) {
                     if (this.subviews[eg].name != "_toolbar" 
                             && this.subviews[eg].name != "_innertop"
@@ -394,189 +339,166 @@
                          
this.subviews[eg].setAttribute("visibility","visible");   
                     }
                 }
-                
                 if (isMicrophonesRoom) {
                     this._innerbottom.setAttribute("visibility", "visible");
                 }
-            
                 this.respectRatio = true;
             }
-            
         ]]>
-    </method>   
+               </method>
 
-       <view name="_innertop" width="${parent.width-2 }" 
-          height="18" x="1" y="1" bgcolor="$once{ 
canvas.getThemeColor('basebgcolorizer') }">
-        <text text="${ parent.parent.chatpartnername }" 
-              onmousedown="parent.parent._startDragState(this)" 
-              onmouseup="parent.parent._removeDragState(this)"
-              width="${ parent.width-2 }" fgcolor="white"
-            fontsize="9">
-            <handler name="onmouseover">
-                //cursor="arrow_draw_panel_cursor" 
-                lz.Cursor.setCursorGlobal("arrow_draw_panel_cursor");
-            </handler>
-            
-            <handler name="onmouseout">
-                lz.Cursor.unlock();
-            </handler>
-        </text>
-    </view>
-    
-    <view name="_innerbottom" width="${parent.width - 2}" x="1" 
y="${parent.height - 19}"
-          height="18" bgcolor="$once{ canvas.getThemeColor('basebgcolorizer') 
}">
-        <text text="${canvas.getLabelName(1434)}"
-              width="${ parent.width-2 }" fgcolor="white"
-              name="title"
-            fontsize="9"/>
-    </view>
-    
-       <view name="_loudness" x="1" visible="${parent.isremote}"
-               y="${parent.height - 20 - ((parent._innerbottom.visible) ? 18 : 
0) }">
-               <method name="setSpeaking" args="bool">
-                       this.loudness.setAttribute('opacity', bool ? 1 : 0.2);
-               </method>
-               <view x="2" y="2" name="loudness" resource="speaking" 
opacity="0.2"
-                       onmouseover="" onmouseout="" >
-                       <handler name="onclick">
-                       <![CDATA[
-                               if (canvas.ismoderator || 
canvas.isAllowedToGiveExclusiveAudio) {
-                                       parent.parent.confirmExclusiveAudio();
-                               } else {
-                                       new 
lz.labelerrorPopupSWF10(canvas,{errorlabelid:1478});
-                               }
-                       ]]>
+               <view name="_innertop" width="${parent.width-2 }" height="18" 
x="1" y="1"
+                       bgcolor="$once{ canvas.getThemeColor('basebgcolorizer') 
}">
+                       <text text="${ parent.parent.chatpartnername }" 
onmousedown="parent.parent._startDragState(this)"
+                               onmouseup="parent.parent._removeDragState(this)"
+                               width="${ parent.width-2 }" fgcolor="white" 
fontsize="9">
+                               <handler name="onmouseover">
+                                       //cursor="arrow_draw_panel_cursor"
+                                       
lz.Cursor.setCursorGlobal("arrow_draw_panel_cursor");
+                               </handler>
+
+                               <handler name="onmouseout">
+                                       lz.Cursor.unlock();
+                               </handler>
+                       </text>
+               </view>
+
+               <view name="_innerbottom" width="${parent.width - 2}" x="1" 
y="${parent.height - 19}" height="18"
+                       bgcolor="$once{ canvas.getThemeColor('basebgcolorizer') 
}">
+                       <text text="${canvas.getLabelName(1434)}" width="${ 
parent.width-2 }" fgcolor="white" name="title" fontsize="9" />
+               </view>
+
+               <view name="_loudness" x="1" visible="${parent.isremote}" 
y="${parent.height - 20 - ((parent._innerbottom.visible) ? 18 : 0) }">
+                       <method name="setSpeaking" args="bool">
+                               this.loudness.setAttribute('opacity', bool ? 1 
: 0.2);
+                       </method>
+                       <view x="2" y="2" name="loudness" resource="speaking" 
opacity="0.2" onmouseover="" onmouseout="">
+                               <handler name="onclick">
+                               <![CDATA[
+                                       if (canvas.ismoderator || 
canvas.isAllowedToGiveExclusiveAudio) {
+                                               
parent.parent.confirmExclusiveAudio();
+                                       } else {
+                                               new 
lz.labelerrorPopupSWF10(canvas,{errorlabelid:1478});
+                                       }
+                               ]]>
+                               </handler>
+                               <labelTooltip inittwice="true" labelid="372" />
+                       </view>
+               </view>
+
+               <view name="_resizeview" x="${ this.parent.width - 16 }" 
valign="bottom" resource="explorer_resize_rsc" cursor="explorer_resizemouse_rsc"
+                       onmousedown="this.parent.doResize(true)" 
onmouseup="this.parent.doResize(false)">
+                       <handler name="oninit">
+                               //if ($debug) Debug.write("setTint");
+                               //TODO: Fix this, does not work at the moment
+                               //canvas.protocol + 
'://code.google.com/p/openmeetings/issues/detail?id=470
+                               
this.setColor(canvas.getThemeColor('baseMousecolorizer'));
                        </handler>
-                       <labelTooltip inittwice="true" labelid="372" />
                </view>
-       </view>
 
-    <view name="_resizeview" x="${ this.parent.width - 16 }" valign="bottom"
-        resource="explorer_resize_rsc" cursor="explorer_resizemouse_rsc" 
-        onmousedown="this.parent.doResize(true)"
-        onmouseup="this.parent.doResize(false)" >
-        <handler name="oninit">
-            //if ($debug) Debug.write("setTint");
-            //TODO: Fix this, does not work at the moment
-            //canvas.protocol + 
'://code.google.com/p/openmeetings/issues/detail?id=470
-            this.setColor(canvas.getThemeColor('baseMousecolorizer'));
-        </handler>      
-    </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});
-                    }
-                }
-            </handler>
-            <labelTooltip name="_tip" labelid="540" />
-        </miniIconsPresenter>       
-        
-        <miniIconsPresenter name="_mute" width="16" height="16" 
iconRessourceName="mute_micro_btn_rsc">
-            <handler name="onclick">
-                parent.parent.silenceMicrophone(!parent.parent.micMuted);
-            </handler>
-            <labelTooltip name="_tip" labelid="1405" />
-        </miniIconsPresenter>
-
-        <miniIconsPresenter x="0" y="0" name="_volume" width="16" height="16" 
iconRessourceName="volume">
-            <handler name="oninit">
-                if (parent.parent.isremote) {
-                    _tip.setAttribute("labelid", 1511);
-                } else {
-                    _tip.setAttribute("labelid", 1512);
-                }
-            </handler>
-            <handler name="onclick">
-                var volume = parent.parent.getStreamVolume();
-
-                var sliderHeight = 120;
-                var sliderX = this.getAttributeRelative('x',canvas) - 2;
-                var pick = new lz.VolumeSlider(canvas, {
-                    height:sliderHeight,
-                    x:sliderX,
-                    y:(parent.getAttributeRelative('y',canvas) - 
sliderHeight/2),
-                    initialNumber:volume,
-                    videoObject:parent.parent
-                });
-                lz.ModeManager.makeModal(pick);
-            </handler>
-            <labelTooltip name="_tip" />
-        </miniIconsPresenter>
-        
-        <miniIconsPresenter name="_minimize"
-            iconRessourceName="btn_presenter_minimize">
-            <handler name="onclick">
-                this.parent.parent.minimize();
-            </handler>
-            <labelTooltip labelid="856" />
-        </miniIconsPresenter>
-        
-        <miniIconsPresenter name="_maximize2" visibility="hidden"
-            iconRessourceName="btn_presenter_maximize">
-            <handler name="onclick">
-                this.parent.parent.reminimize();
-            </handler>
-            <labelTooltip labelid="857" />
-        </miniIconsPresenter>
-        
-    </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});
+                                               }
+                                       }
+                               </handler>
+                               <labelTooltip name="_tip" labelid="540" />
+                       </miniIconsPresenter>
+
+                       <miniIconsPresenter name="_mute" width="16" height="16" 
iconRessourceName="mute_micro_btn_rsc">
+                               <handler name="onclick">
+                                       
parent.parent.silenceMicrophone(!parent.parent.micMuted);
+                               </handler>
+                               <labelTooltip name="_tip" labelid="1405" />
+                       </miniIconsPresenter>
+
+                       <miniIconsPresenter x="0" y="0" name="_volume" 
width="16" height="16" iconRessourceName="volume">
+                               <handler name="oninit">
+                                       _tip.setAttribute("labelid", 
parent.parent.isremote ? 1511 : 1512);
+                               </handler>
+                               <handler name="onclick">
+                                       var volume = 
parent.parent.getStreamVolume();
+
+                                       var sliderHeight = 120;
+                                       var sliderX =
+                                       this.getAttributeRelative('x',canvas) - 
2;
+                                       var pick = new lz.VolumeSlider(canvas, {
+                                                       height:sliderHeight,
+                                                       x:sliderX,
+                                                       
y:(parent.getAttributeRelative('y',canvas) - sliderHeight/2),
+                                                       initialNumber:volume,
+                                                       
videoObject:parent.parent
+                                               });
+                                       lz.ModeManager.makeModal(pick);
+                               </handler>
+                               <labelTooltip name="_tip" />
+                       </miniIconsPresenter>
+
+                       <miniIconsPresenter name="_minimize" 
iconRessourceName="btn_presenter_minimize">
+                               <handler name="onclick">
+                                       this.parent.parent.minimize();
+                               </handler>
+                               <labelTooltip labelid="856" />
+                       </miniIconsPresenter>
+
+                       <miniIconsPresenter name="_maximize2" 
visibility="hidden" iconRessourceName="btn_presenter_maximize">
+                               <handler name="onclick">
+                                       this.parent.parent.reminimize();
+                               </handler>
+                               <labelTooltip labelid="857" />
+                       </miniIconsPresenter>
+
+               </view>
+
+               <view name="_giveExclusiveAudioView" valign="middle" 
align="center" visible="false">
+                       <view name="_micButton" width="40" height="40" 
resource="mic_rsc" showhandcursor="true">
+                               <labelTooltip name="_toolTipTextExclusiveAudio" 
labelid="1386" />
+                       </view>
+               </view>
 
-    <view name="_giveExclusiveAudioView" valign="middle" align="center" 
visible="false">
-        <view name="_micButton" width="40" height="40" resource="mic_rsc" 
showhandcursor="true">
-            <labelTooltip name="_toolTipTextExclusiveAudio" labelid="1386" />
-        </view>
-    </view>
-
-    <handler name="onmouseover">
-        <![CDATA[
-        if (this.isInterview) {
-            return;
-        }
-        if (this.minimized) {
-            return;
-        }
-        if (canvas.ismoderator || canvas.isAllowedToGiveExclusiveAudio) {
-               
this._giveExclusiveAudioView._micButton._toolTipTextExclusiveAudio.doonmouseover();
-            this._giveExclusiveAudioView.setAttribute("visible", true);
-        }
-        ]]>
-    </handler>
-
-    <handler name="onmouseout">
-        <![CDATA[
-        if (this.isInterview) {
-            return;
-        }
-        if (this.minimized) {
-            return;
-        }
-        
this._giveExclusiveAudioView._micButton._toolTipTextExclusiveAudio.cleanHolder();
-        this._giveExclusiveAudioView.setAttribute("visible", false);
-        ]]>
-    </handler> 
-    
-    <handler name="onclick">
+               <handler name="onmouseover">
+        <![CDATA[
+               if (this.isInterview || this.minimized) {
+                   return;
+               }
+               if (canvas.ismoderator || canvas.isAllowedToGiveExclusiveAudio) 
{
+                       
this._giveExclusiveAudioView._micButton._toolTipTextExclusiveAudio.doonmouseover();
+                   this._giveExclusiveAudioView.setAttribute("visible", true);
+               }
+        ]]>
+               </handler>
+
+               <handler name="onmouseout">
+        <![CDATA[
+               if (this.isInterview || this.minimized) {
+                   return;
+               }
+               
this._giveExclusiveAudioView._micButton._toolTipTextExclusiveAudio.cleanHolder();
+               this._giveExclusiveAudioView.setAttribute("visible", false);
+        ]]>
+               </handler>
+
+               <handler name="onclick">
                <![CDATA[
                if (canvas.ismoderator || canvas.isAllowedToGiveExclusiveAudio) 
{
                        
this._giveExclusiveAudioView._micButton._toolTipTextExclusiveAudio.cleanHolder();
@@ -585,219 +507,167 @@
                                new 
lz.labelerrorPopupSWF10(canvas,{errorlabelid:1478});        
                }
                ]]>
-       </handler> 
-    
-    <dragstate name="dragger" />
-    <resizestatemin name="rs" resize_min_width="70" resize_min_height="70"/>
-    <dragHelper name="dragHelper"/>
-    
-    <animator name="_minimizeZoom" attribute="height" 
-              duration="750" to="20" started="false">
-        <handler name="onstop" args="s">
-            parent.reminimizeComplete();
-        </handler>
-    </animator>
+               </handler>
+
+               <dragstate name="dragger" />
+               <resizestatemin name="rs" resize_min_width="70" 
resize_min_height="70" />
+               <dragHelper name="dragHelper" />
+
+               <animator name="_minimizeZoom" attribute="height" 
duration="750" to="20" started="false">
+                       <handler name="onstop" args="s">
+                               parent.reminimizeComplete();
+                       </handler>
+               </animator>
 
-    <handler name="onismoderator" reference="canvas" args="m">
-        if ($debug) Debug.write("###### ismoderator ", m);
+               <handler name="onismoderator" reference="canvas" args="m">
         <![CDATA[
-        
-        if (this.minimized) {
-            this._loudness.setAttribute("x",this.width - 84 - 
(this.isShowMicMute ? 20 : 0));
-            this._loudness.bringToFront();
-        }
+                       if ($debug) Debug.write("###### ismoderator ", m);
+               
+               if (this.minimized) {
+                   this._loudness.setAttribute("x",this.width - 84 - 
(this.isShowMicMute ? 20 : 0));
+                   this._loudness.bringToFront();
+               }
         ]]>
-    </handler>
+               </handler>
 
-       <method name="giveExclusiveAudio">
-               canvas.videoComp_lc.send(canvas.videoComp_lc_name, 
'lc_giveExclusiveAudio', this.publicSID);
-       </method>
-
-    <method name="confirmExclusiveAudio">
-               var so:SharedObject = SharedObject.getLocal('userdata');
-               var userData = so.data;
-               var dontShowExclusiveAudioConfirmation = 
userData["dontShowExclusiveAudioConfirmation"];
-               var exclusiveAudioListener = new Object();
-               exclusiveAudioListener.sendNoConfirmation = function() {};
-               exclusiveAudioListener.sendConfirmation = function(answer, 
remember) {
-                       if (answer) {
-                               giveExclusiveAudio();
-                               if (remember) {
-                                       
userData["dontShowExclusiveAudioConfirmation"] = true;
-                                       so.flush();
-                               }
-                       }
-               };
-               if (dontShowExclusiveAudioConfirmation == true) {
-                       exclusiveAudioListener.sendConfirmation(true, true);
-               } else {
-                       new lz.confirmationSingleSWF10(canvas,{
-                                                                               
        labelid:1428,
-                                                                               
        labeliderror:1539,
-                                                                               
        refObj:exclusiveAudioListener,
-                                                                               
        showCheckBox:true});
-               }
-       </method>
-
-       <!--
-        This will mute the Microphone only to the person that is speaking
-        if the gain is set to zero NOBODY will hear 'em
-     -->
-    <method name="muteMicrophone" args="roomClientObj">
-        <![CDATA[
-        
-        if ($debug) Debug.write("############ muteMicrophone 
",roomClientObj.micMuted);
+               <method name="giveExclusiveAudio">
+                       canvas.videoComp_lc.send(canvas.videoComp_lc_name, 
'lc_giveExclusiveAudio', this.publicSID);
+               </method>
 
-        if (roomClientObj.publicSID == this.publicSID) {
-            if (roomClientObj.publicSID == canvas.publicSID) {
-                if ($debug) Debug.write("Set Mute for Client :: 
",roomClientObj);
-                if (roomClientObj.micMuted) {
-                    if ($debug) Debug.write("############ SET GAIN 0");
-                    this._chatvideoinner._videostream.muteMicro(true);
-                } else {
-                    if ($debug) Debug.write("############ SET GAIN 50");
-                    this._chatvideoinner._videostream.muteMicro(false);
-                }
-            }
-            this.isMutedByModerator = roomClientObj.micMuted;
-            this.setMicMuted(roomClientObj.micMuted);
-            
-        } else {
-            if (!roomClientObj.micMuted) {
-                //Make sure sound is on, in case a user has set it locally to 0
-                //in other words: overwrite any local settings
-                this._chatvideoinner._videostream.setVolume(100);
-            }
-        }
-        ]]>
-    </method>
-
-    <!--
-        This will mute it only locally, that means on other screens
-        the user might be still online and loud
-     -->
-       <method name="silenceMicrophone" args="mute">
-       <![CDATA[
-               if (this.publicSID == canvas.publicSID) {
-                       //self sound turned off
-                       if (mute) {
-                               
canvas.videoComp_lc.send(canvas.videoComp_lc_name, 'lc_switchMicMuted', 
this.publicSID, true);
+               <method name="confirmExclusiveAudio">
+                       var so:SharedObject = SharedObject.getLocal('userdata');
+                       var userData = so.data;
+                       var dontShowExclusiveAudioConfirmation = 
userData["dontShowExclusiveAudioConfirmation"];
+                       var exclusiveAudioListener = new Object();
+                       exclusiveAudioListener.sendNoConfirmation = function() 
{};
+                       exclusiveAudioListener.sendConfirmation = 
function(answer, remember) {
+                                       if (answer) {
+                                               giveExclusiveAudio();
+                                               if (remember) {
+                                                       
userData["dontShowExclusiveAudioConfirmation"] = true;
+                                                       so.flush();
+                                               }
+                                       }
+                               };
+                       if (dontShowExclusiveAudioConfirmation == true) {
+                               exclusiveAudioListener.sendConfirmation(true, 
true);
                        } else {
-                               
this._chatvideoinner._videostream.muteMicro(false);
-                               
canvas.videoComp_lc.send(canvas.videoComp_lc_name, 'lc_switchMicMuted', 
this.publicSID, false);
+                               new lz.confirmationSingleSWF10(canvas,{
+                                       labelid:1428,
+                                       labeliderror:1539,
+                                       refObj:exclusiveAudioListener,
+                                       showCheckBox:true});
                        }
-               } else {
-                       //disable this action for now
-                       if (!canvas.ismoderator) {
-                               new 
lz.labelerrorPopupSWF10(canvas,{errorlabelid:1409});
-                               return;
-                       }
-                       //you can not unmute it locally by putting sound to 100 
cause the gain is set to zero globally in the micro of the sender!
-                       //so setting the sound/volume on the other remote 
clients has zero effect
-                       if (this.isMutedByModerator && !canvas.ismoderator) {
-                               //FIXME: That is not true, you could restart 
audio/video ...
-                               var errorlabelid = 1402;
-                               if (this.publicSID == canvas.publicSID) {
-                                       errorlabelid = 1387;
-                               }
-                               new 
lz.labelerrorPopupSWF10(canvas,{errorlabelid:errorlabelid});
-                               return;
+               </method>
+
+               <!-- This will mute the Microphone only to the person that is 
speaking if the gain is set to zero NOBODY will hear 'em -->
+               <method name="muteMicrophone" args="roomClientObj">
+               <![CDATA[
+                       if ($debug) Debug.write("############ muteMicrophone ", 
roomClientObj.micMuted, roomClientObj.publicSID, this.publicSID);
+                       
+                       if (roomClientObj.publicSID == this.publicSID) {
+                               if ($debug) Debug.write("Set Mute for Client :: 
", roomClientObj);
+                               if ($debug) Debug.write("############ SET GAIN 
" + roomClientObj.micMuted);
+                               
this._chatvideoinner._videostream.muteMicro(roomClientObj.micMuted);
+                               this.isMutedByModerator = 
roomClientObj.micMuted;
+                               this.setMicMuted(roomClientObj.micMuted);
                        }
-                       if (canvas.ismoderator) {
-                               if (mute) {
-                                       
canvas.videoComp_lc.send(canvas.videoComp_lc_name, 'lc_switchMicMuted', 
this.publicSID, true);
-                               } else {
-                                       
canvas.videoComp_lc.send(canvas.videoComp_lc_name, 'lc_switchMicMuted', 
this.publicSID, false);
+               ]]>
+               </method>
+
+               <!-- This will mute it only locally, that means on other 
screens the user might be still online and loud -->
+               <method name="silenceMicrophone" args="mute">
+               <![CDATA[
+                       if ($debug) Debug.write("############ silenceMicrophone 
", this.publicSID);
+                       if (this.publicSID == canvas.publicSID) {
+                               //self sound turned off
+                               
canvas.videoComp_lc.send(canvas.videoComp_lc_name, 'lc_switchMicMuted', 
this.publicSID, mute);
+                               if (!mute) {
+                                       
this._chatvideoinner._videostream.muteMicro(false);
                                }
                        } else {
-                               if (mute) {
-                                       
this._chatvideoinner._videostream.setSoundVolume(0);
+                               //disable this action for now
+                               if (!canvas.ismoderator) {
+                                       new 
lz.labelerrorPopupSWF10(canvas,{errorlabelid:1409});
+                                       return;
+                               }
+                               //you can not unmute it locally by putting 
sound to 100 cause the gain is set to zero globally in the micro of the sender!
+                               //so setting the sound/volume on the other 
remote clients has zero effect
+                               if (this.isMutedByModerator && 
!canvas.ismoderator) {
+                                       //FIXME: That is not true, you could 
restart audio/video ...
+                                       var errorlabelid = this.publicSID == 
canvas.publicSID ? 1387 : 1402;
+                                       new 
lz.labelerrorPopupSWF10(canvas,{errorlabelid:errorlabelid});
+                                       return;
+                               }
+                               if (canvas.ismoderator) {
+                                       
canvas.videoComp_lc.send(canvas.videoComp_lc_name, 'lc_switchMicMuted', 
this.publicSID, mute);
                                } else {
-                                       
this._chatvideoinner._videostream.setSoundVolume(100);
+                                       
this._chatvideoinner._videostream.setSoundVolume(mute ? 0 : 100);
                                }
                        }
-               }
-               this.setMicMuted(mute);
-       ]]>
-       </method>
-
-    <method name="setMicMuted" args="micMuted">
-        <![CDATA[
-        this.micMuted = micMuted;
-        if (micMuted) {
-            this._toolbar._mute._tip.setAttribute("labelid","1406");
-            this._toolbar._mute._itemRsc.setAttribute('frame',2);
-            if (isMicrophonesRoom) {
-                var label = canvas.getLabelName(1435);
-                this._innertop.setAttribute('bgcolor', 
canvas.getThemeColor('basebgcolorizer'));
-                this._innerbottom.setAttribute('bgcolor', 
canvas.getThemeColor('basebgcolorizer'));
-                this._innerbottom.title.setAttribute('text', label);
-            }
-        } else {
-            this._toolbar._mute._tip.setAttribute("labelid","1405");
-            this._toolbar._mute._itemRsc.setAttribute('frame',1);
+                       this.setMicMuted(mute);
+               ]]>
+               </method>
+
+               <method name="setMicMuted" args="micMuted">
+        <![CDATA[
+               this.micMuted = micMuted;
+            this._toolbar._mute._tip.setAttribute("labelid", micMuted ? "1406" 
: "1405");
+            this._toolbar._mute._itemRsc.setAttribute('frame', micMuted ? 2 : 
1);
             if (isMicrophonesRoom) {
-                var label = canvas.getLabelName(1434);
-                this._innertop.setAttribute('bgcolor', "0xFF6600");
-                this._innerbottom.setAttribute('bgcolor', "0xFF6600");
+                var label = canvas.getLabelName(micMuted ? 1435 : 1434);
+                var color = micMuted ? canvas.getThemeColor('basebgcolorizer') 
: "0xFF6600";
+                this._innertop.setAttribute('bgcolor', color);
+                this._innerbottom.setAttribute('bgcolor', color);
                 this._innerbottom.title.setAttribute('text', label);
             }
-        }
         ]]>
-    </method>
+               </method>
 
-    <method name="setStreamVolume" args="v">
-        var stream = this._chatvideoinner._videostream;
-        if (this.isremote) {
-            stream.setSoundVolume(v);
-        } else {
-            stream.setAttribute('micGain', v);
-            stream.micro.gain = v;
-            if (0 == v) {
-                   this.setMicMuted(true);
-                   canvas.videoComp_lc.send(canvas.videoComp_lc_name, 
'lc_switchMicMuted', this.publicSID, true);
-            } else if (micMuted) {
-                this.silenceMicrophone(false);
-            }
-        }
-    </method>
-
-    <method name="getStreamVolume">
-        var stream = this._chatvideoinner._videostream;
-        var volume;
-        if (this.isremote) {
-            volume = Number(stream._ns.soundTransform.volume * 100);
-        } else {
-            volume = stream.micro.gain;
-        }
-        return volume;
-    </method>
-
-    <handler name="onheight" args="value">
-        if (null == initRatio || !respectRatio) {
-            return;
-        }
-        var videoHeight = value - this.videoInsetY - this.bottomBarHeight;
-        var expectedVideoWidth = videoHeight * initRatio;
-        var expectedPodWidth = expectedVideoWidth + this.videoInsetX;
-        if (this.width != expectedPodWidth) {
-            this.setAttribute("width", expectedPodWidth);
-        }
-    </handler>
-
-    <handler name="onwidth" args="value">
-        if (null == initRatio || !respectRatio) {
-            return;
-        }
-        var videoWidth = value - this.videoInsetX;
-        var expectedVideoHeight = videoWidth / initRatio;
-        var expectedPodHeight = expectedVideoHeight + this.videoInsetY + 
this.bottomBarHeight;
-        if (this.height != expectedPodHeight) {
-            this.setAttribute("height", expectedPodHeight);
-        }
-    </handler>
-    
-</class>
+               <method name="setStreamVolume" args="v">
+                       if ($debug) Debug.write("############ setStreamVolume 
", v, this.publicSID);
+                       var stream = this._chatvideoinner._videostream;
+                       if (this.isremote) {
+                               stream.setSoundVolume(v);
+                       } else {
+                               stream.setAttribute('micGain', v);
+                               stream.micro.gain = v;
+                               if (0 == v) {
+                                       this.setMicMuted(true);
+                                       
canvas.videoComp_lc.send(canvas.videoComp_lc_name, 'lc_switchMicMuted', 
this.publicSID, true);
+                               } else if (micMuted) {
+                                       this.silenceMicrophone(false);
+                               }
+                       }
+               </method>
 
+               <method name="getStreamVolume">
+                       var stream = this._chatvideoinner._videostream;
+                       return this.isremote ? 
Number(stream._ns.soundTransform.volume * 100) : stream.micro.gain;
+               </method>
+
+               <handler name="onheight" args="value">
+                       if (null == initRatio || !respectRatio) {
+                               return;
+                       }
+                       var videoHeight = value - this.videoInsetY - 
this.bottomBarHeight;
+                       var expectedVideoWidth = videoHeight * initRatio;
+                       var expectedPodWidth = expectedVideoWidth + 
this.videoInsetX;
+                       if (this.width != expectedPodWidth) {
+                               this.setAttribute("width", expectedPodWidth);
+                       }
+               </handler>
 
+               <handler name="onwidth" args="value">
+                       if (null == initRatio || !respectRatio) {
+                               return;
+                       }
+                       var videoWidth = value - this.videoInsetX;
+                       var expectedVideoHeight = videoWidth / initRatio;
+                       var expectedPodHeight = expectedVideoHeight + 
this.videoInsetY + this.bottomBarHeight;
+                       if (this.height != expectedPodHeight) {
+                               this.setAttribute("height", expectedPodHeight);
+                       }
+               </handler>
+       </class>
 </library>

Modified: 
openmeetings/trunk/singlewebapp/src/org/apache/openmeetings/remote/red5/ScopeApplicationAdapter.java
URL: 
http://svn.apache.org/viewvc/openmeetings/trunk/singlewebapp/src/org/apache/openmeetings/remote/red5/ScopeApplicationAdapter.java?rev=1448558&r1=1448557&r2=1448558&view=diff
==============================================================================
--- 
openmeetings/trunk/singlewebapp/src/org/apache/openmeetings/remote/red5/ScopeApplicationAdapter.java
 (original)
+++ 
openmeetings/trunk/singlewebapp/src/org/apache/openmeetings/remote/red5/ScopeApplicationAdapter.java
 Thu Feb 21 09:17:26 2013
@@ -1174,21 +1174,18 @@ public class ScopeApplicationAdapter ext
                try {
                        log.debug("*..*switchMicMuted publicSID: " + publicSID);
 
-                       Client currentClient = this.sessionManager
-                                       .getClientByPublicSID(publicSID, false, 
null);
+                       Client currentClient = 
sessionManager.getClientByPublicSID(publicSID, false, null);
                        if (currentClient == null) {
                                return -1L;
                        }
 
                        currentClient.setMicMuted(mute);
-                       this.sessionManager.updateClientByStreamId(
-                                       currentClient.getStreamid(), 
currentClient, false, null);
+                       
sessionManager.updateClientByStreamId(currentClient.getStreamid(), 
currentClient, false, null);
 
                        HashMap<Integer, Object> newMessage = new 
HashMap<Integer, Object>();
                        newMessage.put(0, "updateMuteStatus");
                        newMessage.put(1, currentClient);
-                       this.sendMessageWithClient(newMessage);
-
+                       sendMessageWithClient(newMessage);
                } catch (Exception err) {
                        log.error("[switchMicMuted]", err);
                }


Reply via email to