Author: timur
Date: Tue Mar  6 09:13:26 2012
New Revision: 1297391

URL: http://svn.apache.org/viewvc?rev=1297391&view=rev
Log:
OPENMEETINGS-73: fix mute buttons in moderation mini icons

Modified:
    
incubator/openmeetings/trunk/singlewebapp/WebContent/src/modules/conference/flexibleConferenceRoom/moderationMiniIconsEventUserList.lzx
    
incubator/openmeetings/trunk/singlewebapp/WebContent/src/modules/conference/restricted/moderationMiniIconRestricted.lzx

Modified: 
incubator/openmeetings/trunk/singlewebapp/WebContent/src/modules/conference/flexibleConferenceRoom/moderationMiniIconsEventUserList.lzx
URL: 
http://svn.apache.org/viewvc/incubator/openmeetings/trunk/singlewebapp/WebContent/src/modules/conference/flexibleConferenceRoom/moderationMiniIconsEventUserList.lzx?rev=1297391&r1=1297390&r2=1297391&view=diff
==============================================================================
--- 
incubator/openmeetings/trunk/singlewebapp/WebContent/src/modules/conference/flexibleConferenceRoom/moderationMiniIconsEventUserList.lzx
 (original)
+++ 
incubator/openmeetings/trunk/singlewebapp/WebContent/src/modules/conference/flexibleConferenceRoom/moderationMiniIconsEventUserList.lzx
 Tue Mar  6 09:13:26 2012
@@ -129,6 +129,16 @@
     </method>
     
     <simplelayout axis="x" spacing="2" />
+
+    <handler name="onMute" reference="canvas.thishib.switchMicMuted" 
args="event">
+        <![CDATA[
+            if ($debug) Debug.write("onMute ", event.publicSID, event.mute);
+            if(canvas.publicSID == event.publicSID) {
+                canvas.micMuted = event.mute;
+                this.updateIcons();
+            }
+        ]]>
+    </handler>
        
     <miniIconsNew name="_isMod" x="0" width="16" 
innerResource="participants_isMod_rsc" 
                   height="16" showhandcursor="false">
@@ -248,16 +258,7 @@
     <miniIconsNew name="_muteDevice" x="120" width="16" height="16" 
                   innerResource="mute_btn_rsc" showhandcursor="true">
        <handler name="onclick">
-               if (canvas.ismoderator) {
-                       new 
lz.confirmationSingle(canvas.main_content._content.inner,{
-                                                   
labelid:1388,labeliderror:1389,
-                                                   
refReturnMethod:'confirmGloballyOff',
-                                                   
refObj:this,showCheckBox:false});
-               } else {
-                       //Apply for Right to Share Audio/Video
-                var tDate = new Date();
-                
canvas.thishib.sendMessageWithClient.sendMessage("applyForMuteOn",tDate.getTime());
-               }
+            
canvas._videocontainer._videoviewcontent.muteSound(canvas.publicSID, true);
        </handler>
        <method name="confirmGloballyOff" args="bool,t" >
             if ($debug) Debug.write("confirmGloballyOff :: ",bool);
@@ -271,13 +272,7 @@
     <miniIconsNew name="_unMuteDevice" x="120" width="16" height="16" 
innerResource="unmute_btn_rsc" 
                showhandcursor="true" >
        <handler name="onclick">
-            if (canvas.ismoderator) {
-                canvas.thishib.switchMicMuted.setMute(canvas.publicSID,false);
-            } else {
-                //Apply for Right to Share Audio/Video
-                var tDate = new Date();
-                
canvas.thishib.sendMessageWithClient.sendMessage("applyForMuteOff",tDate.getTime());
-            }
+            
canvas._videocontainer._videoviewcontent.muteSound(canvas.publicSID, false);
         </handler>
         <labelTooltip name="_tip" labelid="1395" />
     </miniIconsNew>

Modified: 
incubator/openmeetings/trunk/singlewebapp/WebContent/src/modules/conference/restricted/moderationMiniIconRestricted.lzx
URL: 
http://svn.apache.org/viewvc/incubator/openmeetings/trunk/singlewebapp/WebContent/src/modules/conference/restricted/moderationMiniIconRestricted.lzx?rev=1297391&r1=1297390&r2=1297391&view=diff
==============================================================================
--- 
incubator/openmeetings/trunk/singlewebapp/WebContent/src/modules/conference/restricted/moderationMiniIconRestricted.lzx
 (original)
+++ 
incubator/openmeetings/trunk/singlewebapp/WebContent/src/modules/conference/restricted/moderationMiniIconRestricted.lzx
 Tue Mar  6 09:13:26 2012
@@ -46,7 +46,7 @@
             this._canDraw._text.setAttribute("text",canvas.getLabelName(681));
             this._canDrawModerator.setAttribute("visibility","hidden");
                } else {
-                       if (parent.parent.canDraw) {
+                       if (parent.parent.refObj.canDraw) {
                 this._canDraw.setAttribute("visibility","visible");
                 this._canDraw.isActive = true;
                 this._canDraw.setAttribute("showhandcursor",true);
@@ -78,7 +78,7 @@
             this._denyRemote.setAttribute("visibility","hidden");
             this._denyExclusiveAudio.setAttribute("visibility","hidden");
                } else {
-                       if (parent.parent.canShare) {
+                       if (parent.parent.refObj.canShare) {
                        this._allowScreen.setAttribute("visibility","visible");
                 this._allowScreen.isActive = true;
                 this._allowScreen.setAttribute("showhandcursor",true);
@@ -89,7 +89,7 @@
                                
this._denyScreen.setAttribute("visibility","visible");
                        }
                        
-                       if (parent.parent.canRemote) {
+                       if (parent.parent.refObj.canRemote) {
                        this._allowRemote.setAttribute("visibility","visible");
                 this._allowRemote.isActive = true;
                 this._allowRemote.setAttribute("showhandcursor",true);
@@ -100,7 +100,7 @@
                                
this._denyRemote.setAttribute("visibility","visible");
                        }
 
-            if (parent.parent.canGiveAudio) {
+            if (parent.parent.refObj.canGiveAudio) {
                        
this._allowExclusiveAudio.setAttribute("visibility","visible");
                 this._allowExclusiveAudio.isActive = true;
                 this._allowExclusiveAudio.setAttribute("showhandcursor",true);
@@ -112,7 +112,7 @@
             }
                }
                
-               if (parent.parent.isBroadcasting) {
+               if (parent.parent.refObj.isBroadcasting) {
                        this._allowDevice.setAttribute("visibility","hidden");
                        this._denyDevice.setAttribute("visibility","visible");
                } else {
@@ -120,9 +120,9 @@
             this._denyDevice.setAttribute("visibility","hidden");
                }
                
-               if ($debug) Debug.write("Set micMuted ",parent.parent.micMuted);
+               if ($debug) Debug.write("Set micMuted 
",parent.parent.refObj.micMuted);
                
-               if (parent.parent.micMuted) {
+               if (parent.parent.refObj.micMuted) {
                        this._muteDevice.setAttribute("visibility","hidden");
             this._unMuteDevice.setAttribute("visibility","visible");
                } else {
@@ -294,7 +294,7 @@
     <miniIcons name="_muteDevice" x="120" width="16" height="16" 
resource="mute_btn_rsc" showhandcursor="true">
         <handler name="onclick">
             if ($debug) Debug.write("mute: 
",parent.parent.parent.refObj.publicSID);
-            
canvas.thishib.switchMicMuted.setMute(parent.parent.parent.refObj.publicSID,true);
+            
canvas._videocontainer._videoviewcontent.muteSound(parent.parent.parent.refObj.publicSID,
 true);
         </handler>
         <labelTooltip labelid="1384" />
     </miniIcons>
@@ -303,7 +303,7 @@
                   showhandcursor="true" visibility="hidden">
         <handler name="onclick">
             if ($debug) Debug.write("unmute: 
",parent.parent.parent.refObj.publicSID);
-            
canvas.thishib.switchMicMuted.setMute(parent.parent.parent.refObj.publicSID,false);
+            
canvas._videocontainer._videoviewcontent.muteSound(parent.parent.parent.refObj.publicSID,
 false);
         </handler>
         <labelTooltip labelid="1385" />
     </miniIcons>


Reply via email to