You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@openmeetings.apache.org by so...@apache.org on 2016/09/29 03:05:53 UTC
svn commit: r1762732 [1/2] - in /openmeetings/application:
branches/3.2.x/openmeetings-core/src/main/java/org/apache/openmeetings/core/remote/red5/
branches/3.2.x/openmeetings-flash/src/main/swf/
branches/3.2.x/openmeetings-flash/src/main/swf/base/ bra...
Author: solomax
Date: Thu Sep 29 03:05:52 2016
New Revision: 1762732
URL: http://svn.apache.org/viewvc?rev=1762732&view=rev
Log:
[OPENMEETINGS-1085] Self video seems to work as expected
Added:
openmeetings/application/branches/3.2.x/openmeetings-web/src/main/java/org/apache/openmeetings/web/room/sidebar/icon/activity/
openmeetings/application/branches/3.2.x/openmeetings-web/src/main/java/org/apache/openmeetings/web/room/sidebar/icon/activity/CamActivityIcon.java
openmeetings/application/branches/3.2.x/openmeetings-web/src/main/java/org/apache/openmeetings/web/room/sidebar/icon/activity/RoomActivityIcon.java
openmeetings/application/trunk/openmeetings-web/src/main/java/org/apache/openmeetings/web/room/sidebar/icon/activity/
openmeetings/application/trunk/openmeetings-web/src/main/java/org/apache/openmeetings/web/room/sidebar/icon/activity/CamActivityIcon.java
openmeetings/application/trunk/openmeetings-web/src/main/java/org/apache/openmeetings/web/room/sidebar/icon/activity/RoomActivityIcon.java
Removed:
openmeetings/application/branches/3.2.x/openmeetings-flash/src/main/swf/video/changeDevice.lzx
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/base/remote/baseVideoStream.lzx
openmeetings/application/branches/3.2.x/openmeetings-flash/src/main/swf/base/remote/baseVideoView.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/main.lzx
openmeetings/application/branches/3.2.x/openmeetings-flash/src/main/swf/modules/conference/whiteboard/interviewVideoBox.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/library.lzx
openmeetings/application/branches/3.2.x/openmeetings-flash/src/main/swf/video/videoObjectPlayBroadcast.lzx
openmeetings/application/branches/3.2.x/openmeetings-flash/src/main/swf/video/videoUserProfilePicSWF10.lzx
openmeetings/application/branches/3.2.x/openmeetings-web/src/main/java/org/apache/openmeetings/web/app/Application.java
openmeetings/application/branches/3.2.x/openmeetings-web/src/main/java/org/apache/openmeetings/web/app/Client.java
openmeetings/application/branches/3.2.x/openmeetings-web/src/main/java/org/apache/openmeetings/web/room/RoomPanel.java
openmeetings/application/branches/3.2.x/openmeetings-web/src/main/java/org/apache/openmeetings/web/room/sidebar/RoomSidebar.java
openmeetings/application/branches/3.2.x/openmeetings-web/src/main/java/org/apache/openmeetings/web/room/sidebar/SelfIconsPanel.html
openmeetings/application/branches/3.2.x/openmeetings-web/src/main/java/org/apache/openmeetings/web/room/sidebar/SelfIconsPanel.java
openmeetings/application/branches/3.2.x/openmeetings-web/src/main/java/org/apache/openmeetings/web/room/sidebar/icon/SettingsIcon.java
openmeetings/application/branches/3.2.x/openmeetings-web/src/main/webapp/css/room.css
openmeetings/application/trunk/openmeetings-core/src/main/java/org/apache/openmeetings/core/remote/red5/ScopeApplicationAdapter.java
openmeetings/application/trunk/openmeetings-web/src/main/java/org/apache/openmeetings/web/app/Application.java
openmeetings/application/trunk/openmeetings-web/src/main/java/org/apache/openmeetings/web/app/Client.java
openmeetings/application/trunk/openmeetings-web/src/main/java/org/apache/openmeetings/web/room/RoomPanel.java
openmeetings/application/trunk/openmeetings-web/src/main/java/org/apache/openmeetings/web/room/sidebar/RoomSidebar.java
openmeetings/application/trunk/openmeetings-web/src/main/java/org/apache/openmeetings/web/room/sidebar/SelfIconsPanel.html
openmeetings/application/trunk/openmeetings-web/src/main/java/org/apache/openmeetings/web/room/sidebar/SelfIconsPanel.java
openmeetings/application/trunk/openmeetings-web/src/main/java/org/apache/openmeetings/web/room/sidebar/icon/SettingsIcon.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=1762732&r1=1762731&r2=1762732&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 Thu Sep 29 03:05:52 2016
@@ -985,6 +985,10 @@ public class ScopeApplicationAdapter ext
return -1L;
}
+ public static long nextBroadCastId() {
+ return broadCastCounter.getAndIncrement();
+ }
+
/**
* there will be set an attribute called "broadCastCounter" this is the name
* this user will publish his stream
@@ -997,7 +1001,7 @@ public class ScopeApplicationAdapter ext
IConnection current = Red5.getConnectionLocal();
String streamid = current.getClient().getId();
Client client = sessionManager.getClientByStreamId(streamid, null);
- client.setBroadCastID(broadCastCounter.getAndIncrement());
+ client.setBroadCastID(nextBroadCastId());
sessionManager.updateClientByStreamId(streamid, client, false, null);
return client.getBroadCastID();
} catch (Exception err) {
@@ -1009,49 +1013,37 @@ public class ScopeApplicationAdapter ext
/**
* this must be set _after_ the Video/Audio-Settings have been chosen (see
* editrecordstream.lzx) but _before_ anything else happens, it cannot be
- * applied _after_ the stream has started! avsettings can be: av - video and
- * audio a - audio only v - video only n - no a/v only static image
+ * applied _after_ the stream has started!
+ * avsettings can be:
+ * av - video and audio
+ * a - audio only
+ * v - video only
+ * n - no a/v only static image
* furthermore
*
* @param avsettings
- * @param newMessage
* @param vWidth
* @param vHeight
- * @param roomId
- * @param publicSID
- * @param interviewPodId
+ *
* @return RoomClient being updated in case of no errors, null otherwise
*/
- public Client setUserAVSettings(String avsettings,
- Object newMessage, Integer vWidth, Integer vHeight,
- long roomId, String publicSID, Integer interviewPodId) {
+ public Client setUserAVSettings(String avsettings, Integer vWidth, Integer vHeight) {
try {
- IConnection current = Red5.getConnectionLocal();
- IClient c = current.getClient();
- String streamid = c.getId();
- log.debug("----------- setUserAVSettings {} {} {}", new Object[] {streamid, publicSID, avsettings, newMessage});
- Client parentClient = sessionManager.getClientByPublicSID(publicSID, null);
+ String streamid = Red5.getConnectionLocal().getClient().getId();
+ log.debug("----------- setUserAVSettings {} {} {}", new Object[] {streamid, avsettings});
Client currentClient = sessionManager.getClientByStreamId(streamid, null);
- if (parentClient == null || currentClient == null) {
+ if (currentClient == null) {
log.warn("Failed to find appropriate clients");
return null;
}
currentClient.setAvsettings(avsettings);
- currentClient.setRoomId(roomId);
- currentClient.setPublicSID(publicSID);
currentClient.setVWidth(vWidth);
currentClient.setVHeight(vHeight);
- currentClient.setInterviewPodId(interviewPodId);
- currentClient.setUserId(parentClient.getUserId());
- currentClient.setLastname(parentClient.getLastname());
- currentClient.setFirstname(parentClient.getFirstname());
- currentClient.setPicture_uri(parentClient.getPicture_uri());
sessionManager.updateAVClientByStreamId(streamid, currentClient, null);
- SessionVariablesUtil.initClient(c, publicSID);
- HashMap<String, Object> hsm = new HashMap<String, Object>();
+ HashMap<String, Object> hsm = new HashMap<>();
hsm.put("client", currentClient);
- hsm.put("message", newMessage);
+ hsm.put("message", new Object[]{"avsettings", 0, avsettings});
sendMessageToCurrentScope("sendVarsToMessageWithClient", hsm, true);
return currentClient;
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=1762732&r1=1762731&r2=1762732&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 Thu Sep 29 03:05:52 2016
@@ -32,17 +32,8 @@
ExternalInterface.addCallback("getBrowserInfoCallback", getBrowserInfoCallback);
ExternalInterface.addCallback("getBrowserLangCallback", getBrowserLangCallback);
ExternalInterface.addCallback("showAvSettings", function(isInterview) {
- //FIXME TODO unify
- if (canvas.inner.editRecordStream != null) {
- canvas.inner.editRecordStream.destroy();
- new lz.editRecordStreamSWF10(canvas.inner, {
- name: "editRecordStream"
- , isSyncUpdate: true
- , isInterview: isInterview
- , standalone: true
- //, interviewPodId: interviewPodId
- });
- }
+ if ($debug) Debug.write("showAvSettings ", isInterview);
+ canvas.commonVideoViewContent.createEditRecordStream(isInterview, true, false);
});
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=1762732&r1=1762731&r2=1762732&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 Thu Sep 29 03:05:52 2016
@@ -836,6 +836,7 @@
if ($debug) Debug.write("clientUpdated changes ###### ");
if (client.publicSID == canvas.publicSID) {
if ($debug) Debug.write("Its about You ", client);
+ canvas.currentClient = client;
canvas.setAttribute("isAllowedToDraw", client.canDraw);
canvas.setAttribute("isAllowedToScreenShare", client.canShare);
canvas.setAttribute("isAllowedToRemoteControl", client.canRemote);
@@ -849,13 +850,11 @@
if (canvas.thishib.modus == "interview") {
canvas._drawarea.newInterviewStarting(client);
} else {
- canvas.commonVideoViewContent.createEditRecordStream(false, false, -1);
+ canvas.commonVideoViewContent.createEditRecordStream(false, false, false);
}
canvas.setAttribute("lastBroadCastingUser", client);
} else {
- if (canvas.inner.editRecordStream != null) {
- canvas.inner.editRecordStream.destroy();
- }
+ canvas.commonVideoViewContent.removeVideoByUser(canvas.publicSID);
}
}
]]>
@@ -931,7 +930,7 @@
<method name="sendVarsToMessageWithClient" args="value">
<![CDATA[
//The onResult-Handler will be called be the rtmpconnection
- if ($debug) Debug.write("sendVarsToMessageWithClient : ", value,value.message, value.message[0]);
+ if ($debug) Debug.write("sendVarsToMessageWithClient : ", value, value.message, value.message[0]);
if (value[0] == 'kick' || value.message[0] == 'kick') {
if ($debug) Debug.write("!!!!!! THIS USER GOING TO BE KICKED");
this.showKickMessage = true;
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=1762732&r1=1762731&r2=1762732&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 Thu Sep 29 03:05:52 2016
@@ -540,16 +540,12 @@
main_content.setAttribute("bgcolor",canvas.getThemeColor('mainBackgroundColor'));
</method>
- <method name="getPictureUrl" args="pictureuri,extraParams">
+ <method name="getPictureUrl" args="userId, pictureuri">
<![CDATA[
var pUri = (pictureuri == null || pictureuri.length == 0) ? "d.jpg" : pictureuri;
var downloadurl = pUri;
if (!pUri.startsWith("http://") && !pUri.startsWith("https://")) {
- pUri = "_profile_" + pUri;
-
- downloadurl = canvas.getUrl() + 'DownloadHandler?fileName=' + pUri
- + '&parentPath=&room_id=&r=' + (new Date()).getTime()
- + extraParams + '&sid='+canvas.sessionId;
+ downloadurl = canvas.getUrl() + 'profile/' + userId;
}
if($debug) Debug.write("getPictureUrl/downloadurl ", downloadurl);
return downloadurl;
Modified: openmeetings/application/branches/3.2.x/openmeetings-flash/src/main/swf/base/remote/baseVideoStream.lzx
URL: http://svn.apache.org/viewvc/openmeetings/application/branches/3.2.x/openmeetings-flash/src/main/swf/base/remote/baseVideoStream.lzx?rev=1762732&r1=1762731&r2=1762732&view=diff
==============================================================================
--- openmeetings/application/branches/3.2.x/openmeetings-flash/src/main/swf/base/remote/baseVideoStream.lzx (original)
+++ openmeetings/application/branches/3.2.x/openmeetings-flash/src/main/swf/base/remote/baseVideoStream.lzx Thu Sep 29 03:05:52 2016
@@ -269,9 +269,11 @@
<method name="_stop">
if ($debug) Debug.write("STOP: ",this.mode,this._ns);
//Stop NetStream
- if (this._ns==null) return;
+ if (this._ns == null) return;
this.camera = null;
this.micro = null;
+ this._ns.attachCamera(null);
+ this._ns.attachAudio(null);
if (this.mode == "play") {
this.soundRefMC = null;
this.soundRef = null;
Modified: openmeetings/application/branches/3.2.x/openmeetings-flash/src/main/swf/base/remote/baseVideoView.lzx
URL: http://svn.apache.org/viewvc/openmeetings/application/branches/3.2.x/openmeetings-flash/src/main/swf/base/remote/baseVideoView.lzx?rev=1762732&r1=1762731&r2=1762732&view=diff
==============================================================================
--- openmeetings/application/branches/3.2.x/openmeetings-flash/src/main/swf/base/remote/baseVideoView.lzx (original)
+++ openmeetings/application/branches/3.2.x/openmeetings-flash/src/main/swf/base/remote/baseVideoView.lzx Thu Sep 29 03:05:52 2016
@@ -89,10 +89,13 @@
<method name="clear">
if ($debug) Debug.write("Select unattach :3");
- var vid = this._getflashvideo();
- vid.attachNetStream(null);
- vid.attachCamera(null);
- this.__LZvideo.clear();
+ if (this.__LZvideo != null) {
+ this.__LZvideo.attachCamera(null);
+ this.__LZvideo.attachNetStream(null);
+ this.__LZvideo.clear();
+ this.sprite.removeChild(this.__LZvideo);
+ this.__LZvideo = null;
+ }
if ($debug) Debug.write("Select unattach : 4");
</method>
</class>
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=1762732&r1=1762731&r2=1762732&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 Thu Sep 29 03:05:52 2016
@@ -8,8 +8,8 @@
"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
-
+ 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
@@ -40,16 +40,13 @@
canvas.currentClient.canVideo = value;
</method>
- <method name="createEditRecordStream" args="syncUpdate,isInterview,interviewPodId">
- if($debug) Debug.info("createEditRecordStream,", syncUpdate, isInterview, interviewPodId, canvas.currentClient);
- if (canvas.inner.editRecordStream != null)
- canvas.inner.editRecordStream.destroy();
- new lz.editRecordStreamSWF10(canvas.inner, {
- name:"editRecordStream",
- isSyncUpdate:syncUpdate,
- isInterview:isInterview,
- interviewPodId:interviewPodId
- });
+ <method name="createEditRecordStream" args="isInterview, standalone, isSyncUpdate">
+ if($debug) Debug.info("createEditRecordStream,", isInterview, standalone, canvas.currentClient);
+ new lz.editRecordStreamSWF10(canvas, {
+ isInterview: isInterview,
+ standalone: standalone,
+ isSyncUpdate: isSyncUpdate
+ });
return;
</method>
@@ -133,10 +130,9 @@
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"]);
@@ -152,14 +148,14 @@
<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){
+ //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);
+ if ($debug) Debug.warn(" - getVideoObjectByPublicSID - DID NOT FIND THE USER BY ", publicSID);
return null;
]]>
</method>
@@ -299,10 +295,8 @@
if (obj != null) {
obj.resetValues();
}
- if (canvas.publicSID == publicSID && canvas.inner.editRecordStream != null) {
- canvas.inner.editRecordStream.cleanVideos();
- canvas.inner.editRecordStream.destroy();
- canvas.inner.editRecordStream = null;
+ if (canvas.publicSID == publicSID && canvas.editRecordStream != null) {
+ canvas.editRecordStream.destroy();
}
return obj;
]]>
@@ -406,8 +400,8 @@
}
this.subviews[0].destroy();
}
- if (canvas.inner.editRecordStream != null) {
- canvas.inner.editRecordStream.destroy();
+ if (canvas.editRecordStream != null) {
+ canvas.editRecordStream.destroy();
}
return;
]]>
@@ -421,19 +415,6 @@
]]>
</method>
- <!---
- Shows the window with device settings
- -->
- <method name="changeDevice">
- <![CDATA[
- if ($debug) Debug.write("changeDevice");
- new lz.changeDevice(canvas.inner, {
- name:"changeDeviceDialog"
- });
- return;
- ]]>
- </method>
-
<method name="updateFirstLastName" args="publicSID,first,last">
var v = getVideoObjectByPublicSID(publicSID);
if (v != null) {
@@ -646,7 +627,7 @@
canvas.screenSharingDialogContainer.destroy();
canvas.screenSharingDialogContainer = null;
}
- parent._videoComponent.clearAll();
+ canvas.commonVideoViewContent.clearAll();
]]>
</method>
Modified: openmeetings/application/branches/3.2.x/openmeetings-flash/src/main/swf/main.lzx
URL: http://svn.apache.org/viewvc/openmeetings/application/branches/3.2.x/openmeetings-flash/src/main/swf/main.lzx?rev=1762732&r1=1762731&r2=1762732&view=diff
==============================================================================
--- openmeetings/application/branches/3.2.x/openmeetings-flash/src/main/swf/main.lzx (original)
+++ openmeetings/application/branches/3.2.x/openmeetings-flash/src/main/swf/main.lzx Thu Sep 29 03:05:52 2016
@@ -62,7 +62,7 @@
canvas.setDefaultContextMenu(cmenu);
cmenu.hideBuiltInItems();
if($debug) Debug.write("main.lzx/oninit:",this);
- canvas.commonVideoViewContent = new lz.commonVideoViewContentSWF10(this, {name:'_videoComponent'});
+ canvas.commonVideoViewContent = new lz.commonVideoViewContentSWF10(canvas);
canvas.currentModeratorList = [];
canvas.removeModeratorList = [];
]]></handler>
@@ -94,7 +94,7 @@
var baseContent = this.inner.subviews[0].close();
for (var eg in this.inner.subviews) {
if($debug) Debug.write("main.lzx/main_content._content.inner.clearAll()-subviews: ",this.inner.subviews[eg]);
- if (eg!=0) this.inner.subviews[eg].close();
+ if (eg!=0) this.inner.subviews[eg].close();
}
}
}
@@ -151,6 +151,4 @@
from="0" to="0.7" started="false" duration="250" />
<text name="_text" align="right" y="56" fontsize="14" fgcolor="red">Loading...</text>
</view>
-
- <view name="inner"></view>
</canvas>
Modified: openmeetings/application/branches/3.2.x/openmeetings-flash/src/main/swf/modules/conference/whiteboard/interviewVideoBox.lzx
URL: http://svn.apache.org/viewvc/openmeetings/application/branches/3.2.x/openmeetings-flash/src/main/swf/modules/conference/whiteboard/interviewVideoBox.lzx?rev=1762732&r1=1762731&r2=1762732&view=diff
==============================================================================
--- openmeetings/application/branches/3.2.x/openmeetings-flash/src/main/swf/modules/conference/whiteboard/interviewVideoBox.lzx (original)
+++ openmeetings/application/branches/3.2.x/openmeetings-flash/src/main/swf/modules/conference/whiteboard/interviewVideoBox.lzx Thu Sep 29 03:05:52 2016
@@ -77,6 +77,7 @@
if ($debug) Debug.write("startInterView :: ");
var tx = this.getAttributeRelative("x",canvas);
var ty = this.getAttributeRelative("y",canvas);
+ //TODO
canvas.commonVideoViewContent.createEditRecordStream(false, true, this.interviewPodId);
</method>
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=1762732&r1=1762731&r2=1762732&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 Thu Sep 29 03:05:52 2016
@@ -1,11 +1,23 @@
<?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>
@@ -77,117 +89,117 @@
</handler>
<handler name="oninit">
- <![CDATA[
- this.clientVars = new Array();
- this.clientVars['User']='No User Connected';
-
- if (this.isInterview) {
- this._toolbar._minimize.setAttribute("visibility","hidden");
- this._resizeview.setAttribute("visibility","hidden");
- this._innerbottom.setAttribute("visibility","hidden");
- return;
- }
-
- if (this.custom) {
- this._toolbar._minimize.setAttribute("visibility","hidden");
- this._resizeview.setAttribute("visibility","hidden");
- this._toolbar.setAttribute("visibility","hidden");
- this._resizeview.setAttribute("visibility","hidden");
- this._loudness.setAttribute("visibility","hidden");
- this._innertop.setAttribute("visibility","hidden");
- this._innerbottom.setAttribute("visibility","hidden");
- }
- this.setShadow();
-
- if (this.publicSID == canvas.publicSID) {
- this._toolbar._resync._tip.setAttribute("labelid",610);
- }
- this._giveExclusiveAudioView.bringToFront();
-
- this.isMicrophonesRoom = canvas.currentRoomObj.showMicrophoneStatus;
- if (isMicrophonesRoom) {
- this._innertop.setAttribute("bgcolor", "0xFF6600");
- this._innerbottom.setAttribute("bgcolor", "0xFF6600");
- } else {
- this._innerbottom.setAttribute("visibility", "hidden");
- }
- ]]>
+ <![CDATA[
+ this.clientVars = new Array();
+ this.clientVars['User']='No User Connected';
+
+ if (this.isInterview) {
+ this._toolbar._minimize.setAttribute("visibility","hidden");
+ this._resizeview.setAttribute("visibility","hidden");
+ this._innerbottom.setAttribute("visibility","hidden");
+ return;
+ }
+
+ if (this.custom) {
+ this._toolbar._minimize.setAttribute("visibility","hidden");
+ this._resizeview.setAttribute("visibility","hidden");
+ this._toolbar.setAttribute("visibility","hidden");
+ this._resizeview.setAttribute("visibility","hidden");
+ this._loudness.setAttribute("visibility","hidden");
+ this._innertop.setAttribute("visibility","hidden");
+ this._innerbottom.setAttribute("visibility","hidden");
+ }
+ this.setShadow();
+
+ if (this.publicSID == canvas.publicSID) {
+ this._toolbar._resync._tip.setAttribute("labelid",610);
+ }
+ this._giveExclusiveAudioView.bringToFront();
+
+ this.isMicrophonesRoom = canvas.currentRoomObj.showMicrophoneStatus;
+ if (isMicrophonesRoom) {
+ this._innertop.setAttribute("bgcolor", "0xFF6600");
+ this._innerbottom.setAttribute("bgcolor", "0xFF6600");
+ } else {
+ this._innerbottom.setAttribute("visibility", "hidden");
+ }
+ ]]>
</handler>
<handler name="ony">
<![CDATA[
- if (this.isInterview || this.custom || canvas.currentRoomObj.hideWhiteboard) {
- return;
- }
- var bounds = this.getBounds();
- var parentBounds = canvas.getBounds();
- if (bounds.y < 0) {
- this.setAttribute('y',0);
- }
- if (bounds.y > (parentBounds.height - bounds.height)) {
- this.setAttribute('y', parentBounds.height - bounds.height );
- }
- ]]>
+ if (this.isInterview || this.custom || canvas.currentRoomObj.hideWhiteboard) {
+ return;
+ }
+ var bounds = this.getBounds();
+ var parentBounds = canvas.getBounds();
+ if (bounds.y < 0) {
+ this.setAttribute('y',0);
+ }
+ if (bounds.y > (parentBounds.height - bounds.height)) {
+ this.setAttribute('y', parentBounds.height - bounds.height );
+ }
+ ]]>
</handler>
<handler name="onx">
<![CDATA[
- if (this.isInterview || this.custom) {
- return;
- }
+ if (this.isInterview || this.custom) {
+ return;
+ }
var bounds = this.getBounds();
- var parentBounds = canvas.getBounds();
- if (bounds.x < 0) {
- this.setAttribute('x',0);
- }
-
- if (bounds.x > (parentBounds.width - bounds.width)) {
- this.setAttribute('x', parentBounds.width - bounds.width );
- }
- ]]>
+ var parentBounds = canvas.getBounds();
+ if (bounds.x < 0) {
+ this.setAttribute('x',0);
+ }
+
+ 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];
- }
- ]]>
+ <![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;
- }
- var h=this.width * this.initH/this.initW;
- h=((h < this.initH ) ? initH : h);
+ <![CDATA[
+ if (!this.respectRatio) {
+ return;
+ }
+ var h=this.width * this.initH/this.initW;
+ h=((h < this.initH ) ? initH : h);
- if ($debug) Debug.write("setItemContraintsWidth",this.respectRatio,'orig',this.height,this.width,'new h',h);
+ if ($debug) Debug.write("setItemContraintsWidth",this.respectRatio,'orig',this.height,this.width,'new h',h);
- this.setAttribute("height",h);
- ]]>
+ this.setAttribute("height",h);
+ ]]>
</method>
<method name="setItemContraintsHeight" args="unused">
- <![CDATA[
- if (!this.respectRatio) {
- return;
- }
- var w=this.height * this.initW/this.initH;
- w=((w < this.initW ) ? initW : w);
+ <![CDATA[
+ if (!this.respectRatio) {
+ return;
+ }
+ var w=this.height * this.initW/this.initH;
+ w=((w < this.initW ) ? initW : w);
- if ($debug) Debug.write("setItemContraintsHeight",this.respectRatio,'orig',this.height,this.width,'new w',w);
+ if ($debug) Debug.write("setItemContraintsHeight",this.respectRatio,'orig',this.height,this.width,'new w',w);
- this.setAttribute("width",w);
- ]]>
+ this.setAttribute("width",w);
+ ]]>
</method>
<method name="updateAVSettingsSymbol" args="rcl">
@@ -218,16 +230,14 @@
<!--- resets all values and stops the streaming -->
<method name="resetValues">
<![CDATA[
- if ($debug) Debug.write("resetValues: ",this.isremote);
- this.clientVars=null;
- if (!this.isremote) {
- deleteVideoConfProfilePic();
- }
- if (this.isremote){
- this._chatvideoinner._videostream.restart();
- } else {
- this._chatvideoinner._videostream._stop();
- }
+ if ($debug) Debug.write("resetValues: ", this.isremote);
+ this.clientVars = null;
+ if (this.isremote) {
+ this._chatvideoinner._videostream.restart();
+ } else {
+ deleteVideoConfProfilePic();
+ this._chatvideoinner._videostream._stop();
+ }
]]>
</method>
@@ -262,89 +272,89 @@
<!--- @keywords private -->
<method name="_removeDragState" args="obj">
- <![CDATA[
- lz.Cursor.unlock();
-
- if (this.x < 0) {
- this.setAttribute("x",20);
- }
-
- if (this.y < 0) {
- this.setAttribute("y",20);
- }
-
- if (this.x+this.width > parent.width) {
- this.setAttribute("x",parent.width - this.width - 20);
- }
-
- if (this.y+this.height > parent.height) {
- this.setAttribute("y",parent.height - this.height - 20);
- }
- dragHelper.remove();
- this.dragger.remove();
- ]]>
+ <![CDATA[
+ lz.Cursor.unlock();
+
+ if (this.x < 0) {
+ this.setAttribute("x",20);
+ }
+
+ if (this.y < 0) {
+ this.setAttribute("y",20);
+ }
+
+ if (this.x+this.width > parent.width) {
+ this.setAttribute("x",parent.width - this.width - 20);
+ }
+
+ if (this.y+this.height > parent.height) {
+ this.setAttribute("y",parent.height - this.height - 20);
+ }
+ dragHelper.remove();
+ this.dragger.remove();
+ ]]>
</method>
<method name="minimize">
- <![CDATA[
- this.respectRatio = false;
-
- this.setAttribute("minimized",true);
-
- this._toolbar._minimize.setAttribute("visibility","hidden");
- this._toolbar._maximize2.setAttribute("visibility","visible");
-
- for (var eg in this.subviews) {
- if (this.subviews[eg].name != "_toolbar"
- && this.subviews[eg].name != "_innertop"
- && this.subviews[eg].name != "_loudness") {
- this.subviews[eg].setAttribute("visibility","hidden");
- }
- }
-
- this._loudness.setAttribute("x",this.width - 84 - (this.isShowMicMute ? 20 : 0));
- this._loudness.bringToFront();
-
- this.initialHeight = this.height;
- //this.setAttribute("height",20);
- this._minimizeZoom.setAttribute("to",20);
- this._minimizeZoom.setAttribute('started', true);
- ]]>
+ <![CDATA[
+ this.respectRatio = false;
+
+ this.setAttribute("minimized",true);
+
+ this._toolbar._minimize.setAttribute("visibility","hidden");
+ this._toolbar._maximize2.setAttribute("visibility","visible");
+
+ for (var eg in this.subviews) {
+ if (this.subviews[eg].name != "_toolbar"
+ && this.subviews[eg].name != "_innertop"
+ && this.subviews[eg].name != "_loudness") {
+ this.subviews[eg].setAttribute("visibility","hidden");
+ }
+ }
+
+ this._loudness.setAttribute("x",this.width - 84 - (this.isShowMicMute ? 20 : 0));
+ this._loudness.bringToFront();
+
+ this.initialHeight = this.height;
+ //this.setAttribute("height",20);
+ this._minimizeZoom.setAttribute("to",20);
+ this._minimizeZoom.setAttribute('started', true);
+ ]]>
</method>
<method name="reminimize">
- <![CDATA[
- this.setAttribute("minimized",false);
-
- this._toolbar._minimize.setAttribute("visibility","visible");
- this._toolbar._maximize2.setAttribute("visibility","hidden");
-
- this._loudness.setAttribute("x",1);
-
- //this.setAttribute("height",this.initialHeight);
- if ($debug) Debug.write("this.initialHeight ",this.initialHeight);
- this._minimizeZoom.setAttribute("to",this.initialHeight);
- this._minimizeZoom.setAttribute('started', true);
- ]]>
+ <![CDATA[
+ this.setAttribute("minimized",false);
+
+ this._toolbar._minimize.setAttribute("visibility","visible");
+ this._toolbar._maximize2.setAttribute("visibility","hidden");
+
+ this._loudness.setAttribute("x",1);
+
+ //this.setAttribute("height",this.initialHeight);
+ if ($debug) Debug.write("this.initialHeight ",this.initialHeight);
+ this._minimizeZoom.setAttribute("to",this.initialHeight);
+ this._minimizeZoom.setAttribute('started', true);
+ ]]>
</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"
- && this.subviews[eg].name != "_loudness"
- && this.subviews[eg].name != "_innerbottom") {
- this.subviews[eg].setAttribute("visibility","visible");
- }
- }
- if (isMicrophonesRoom) {
- this._innerbottom.setAttribute("visibility", "visible");
- }
- this.respectRatio = true;
- }
- ]]>
+ <![CDATA[
+ if (!this.minimized) {
+ for (var eg in this.subviews) {
+ if (this.subviews[eg].name != "_toolbar"
+ && this.subviews[eg].name != "_innertop"
+ && this.subviews[eg].name != "_loudness"
+ && this.subviews[eg].name != "_innerbottom") {
+ this.subviews[eg].setAttribute("visibility","visible");
+ }
+ }
+ if (isMicrophonesRoom) {
+ this._innerbottom.setAttribute("visibility", "visible");
+ }
+ this.respectRatio = true;
+ }
+ ]]>
</method>
<view name="_innertop" width="${parent.width-2 }" height="18" x="1" y="1"
@@ -476,35 +486,35 @@
</view>
<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);
- }
- ]]>
+ <![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);
- ]]>
+ <![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();
- this.confirmExclusiveAudio();
- } else {
- new lz.labelerrorPopup(canvas,{errorlabelid:1478});
- }
+ if (canvas.ismoderator || canvas.isAllowedToGiveExclusiveAudio) {
+ this._giveExclusiveAudioView._micButton._toolTipTextExclusiveAudio.cleanHolder();
+ this.confirmExclusiveAudio();
+ } else {
+ new lz.labelerrorPopup(canvas,{errorlabelid:1478});
+ }
]]>
</handler>
@@ -519,14 +529,14 @@
</animator>
<handler name="onismoderator" reference="canvas" args="m">
- <![CDATA[
+ <![CDATA[
if ($debug) Debug.write("###### ismoderator ", m);
-
- if (this.minimized) {
- this._loudness.setAttribute("x",this.width - 84 - (this.isShowMicMute ? 20 : 0));
- this._loudness.bringToFront();
- }
- ]]>
+
+ if (this.minimized) {
+ this._loudness.setAttribute("x",this.width - 84 - (this.isShowMicMute ? 20 : 0));
+ this._loudness.bringToFront();
+ }
+ ]]>
</handler>
<method name="giveExclusiveAudio">
@@ -614,18 +624,18 @@
</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(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);
- }
- ]]>
+ <![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(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 name="setStreamVolume" args="v">
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=1762732&r1=1762731&r2=1762732&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 Thu Sep 29 03:05:52 2016
@@ -32,9 +32,8 @@
-->
-<class name="editRecordStreamSWF10" extends="labelExplorerBox" labelid="51"
- width="680" height="540" x="14" y="-540" >
-
+<class name="editRecordStreamSWF10" extends="labelExplorerBox" labelid="51"
+ width="680" height="540" x="14" y="-540" >
<switch>
<when property="$as3">
<passthrough>
@@ -50,7 +49,6 @@
</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" />
@@ -58,28 +56,18 @@
<attribute name="chosenSetting" value="null" />
<attribute name="currentClient" value="null" />
- <attribute name="remoteMessage" 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" />
-
<attribute name="interviewPodId" value="0" type="number" />
-
<attribute name="lastRecorded" value="" type="string" />
-
<attribute name="isRunning" value="false" type="boolean" />
-
<attribute name="recordingsCounter" value="5" type="number" />
-
<attribute name="timerIsRunning" value="false" type="boolean" />
-
<attribute name="counterDelegate" value="null" />
<method name="startTimer">
@@ -94,7 +82,6 @@
lz.Timer.resetTimer(this.counterDelegate, 1000);
this._text._info.setAttribute("text",""+this.recordingsCounter+" sec");
-
} else {
this._text.setAttribute("visibility","hidden");
this.doStop();
@@ -112,41 +99,49 @@
<handler name="oninit">
<![CDATA[
- //Make this view the upmost in the z-Index order
- canvas.inner.bringToFront();
+ if (canvas.editRecordStream != null) {
+ canvas.editRecordStream.destroy();
+ }
+ canvas.editRecordStream = this;
+
this.counterDelegate = new LzDelegate(this, "count");
if ($debug) Debug.write("this.myvideocontainer ",this.myvideocontainer);
if ($debug) Debug.write("editrecordstream ###################### ");
- var sharedData = null;//this.checkDeviceSettingsRememberStatus();
- if(sharedData != null) {
- this.chosenCam = sharedData["cam"];
- this.chosenMic = sharedData["mic"];
- this.cam_default_width = canvas.isInterview ? 320 : sharedData["width"];
- this.cam_default_height = canvas.isInterview ? 260 : sharedData["height"];
- this.chosenSetting = sharedData["avstored"];
- this.remoteMessage = new Array();
- this.remoteMessage[0] = 'avsettings';
- this.remoteMessage[2] = this.chosenSetting;
- this.getBroadCastId.doCall();
- } else {
+ initItems();
+ if (standalone) {
if (this.doDefaultAnimation && !canvas.isInterview) {
this._chooseDeviceAnimation.setAttribute('started', true);
} else {
this.setAttribute("y", initY);
}
- this.initItemsAndDefaultAttachCamera();
+ this.executeAttachCamera = true;
+ this.attachCamera();
+ } else {
+ storeChosen();
+ myvideocontainer = canvas.commonVideoViewContent.createVideoObject(canvas.publicSID, true, interviewPodId, canvas.currentClient);
+
+ setUserAVSettings.doCall();
}
+ //TODO check this
if (canvas.isInterview) {
- if ($debug) Debug.write("Is interview ",interviewPodId);
- this.setAttribute("x",canvas["interviewPod"+interviewPodId+"_x"]);
- this.setAttribute("y",canvas["interviewPod"+interviewPodId+"_y"]);
+ if ($debug) Debug.write("Is interview ", interviewPodId);
+ //this.setAttribute("x",canvas["interviewPod"+interviewPodId+"_x"]);
+ //this.setAttribute("y",canvas["interviewPod"+interviewPodId+"_y"]);
}
]]>
</handler>
-
+
+ <handler name="ondestroy">
+ <![CDATA[
+ if ($debug) Debug.write("editrecordstream::ondestroy ");
+ cleanVideos();
+ canvas.editRecordStream = null;
+ ]]>
+ </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.
@@ -183,56 +178,33 @@
]]>
</method>
-
- <netRemoteCallHib name="getBroadCastId" funcname="getBroadCastId" remotecontext="$once{ canvas.thishib }" >
- <handler name="ondata" args="value">
- <![CDATA[
- if ($debug) Debug.write("getBroadCastId",value,canvas.publicSID);
- parent.myvideocontainer = canvas._videoComponent.createVideoObject(canvas.publicSID, true, parent.interviewPodId, canvas.currentClient);
-
- if ($debug) Debug.write("parent.setUserAVSettings -1- ",parent.chosenSetting);
- if ($debug) Debug.write("parent.setUserAVSettings -2- ",parent.remoteMessage);
- if ($debug) Debug.write("parent.setUserAVSettings -3- ",parent.cam_default_width);
- if ($debug) Debug.write("parent.setUserAVSettings -4- ",parent.cam_default_height);
- if ($debug) Debug.write("parent.setUserAVSettings -5a- ",canvas.currentRoomObj.id);
- if ($debug) Debug.write("parent.setUserAVSettings -6- ",canvas.publicSID);
-
- parent.setUserAVSettings.doCall();
- ]]>
- </handler>
- </netRemoteCallHib>
-
<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.remoteMessage;</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>
- <netparam><method name="getValue">return canvas.currentRoomObj.id;</method></netparam>
- <netparam><method name="getValue">return canvas.publicSID;</method></netparam>
- <netparam><method name="getValue">return parent.parent.interviewPodId;</method></netparam>
<handler name="ondata" args="value">
- <![CDATA[
- if ($debug) Debug.write("setUserAVSettings",value);
- parent.currentClient = value;
- parent.doStartConference();
- ]]>
+ <![CDATA[
+ if ($debug) Debug.write("setUserAVSettings",value);
+ parent.currentClient = value;
+ parent.doStartConference();
+ ]]>
</handler>
</netRemoteCallHib>
<method name="storelocaldata">
- <![CDATA[
- //if ($debug) Debug.write("sharedobject store:: [width, height] : [" + this.cam_default_width + ", " + this.cam_default_height + "]");
- var t:SharedObject = SharedObject.getLocal('userdata');
- var g = t.data;
- if (g==null) g = new Array();
- 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();
- ]]>
+ <![CDATA[
+ //if ($debug) Debug.write("sharedobject store:: [width, height] : [" + this.cam_default_width + ", " + this.cam_default_height + "]");
+ var t:SharedObject = SharedObject.getLocal('userdata');
+ var g = t.data;
+ if (g==null) g = new Array();
+ 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">
@@ -390,18 +362,18 @@
</method>
<method name="doPlay">
- <![CDATA[
- if (this.lastRecorded == "") {
- //Error - nothing recorded yet
- if ($debug) Debug.warn("Nothing to Play");
- } else {
- this._play.setAttribute("enabled",true);
- this._video.content._publisher.setAttribute("visibility","hidden");
- this._video.content._viewer.setAttribute("visibility","visible");
- var videoview = this._video.content._viewer._chatvideoinner._videostream;
- videoview.justPlayStream(this.lastRecorded+".flv",0);
- }
- ]]>
+ <![CDATA[
+ if (this.lastRecorded == "") {
+ //Error - nothing recorded yet
+ if ($debug) Debug.warn("Nothing to Play");
+ } else {
+ this._play.setAttribute("enabled",true);
+ this._video.content._publisher.setAttribute("visibility","hidden");
+ this._video.content._viewer.setAttribute("visibility","visible");
+ var videoview = this._video.content._viewer._chatvideoinner._videostream;
+ videoview.justPlayStream(this.lastRecorded+".flv",0);
+ }
+ ]]>
</method>
<method name="doStop">
@@ -418,9 +390,8 @@
<animator name="_chooseDeviceAnimation" started="false" attribute="y" to="40" duration="750" />
-
<labelText fontstyle="bold" labelid="758"
- width="${ parent.width-2 }" height="30" multiline="true" y="20" />
+ width="${ parent.width-2 }" height="30" multiline="true" y="20" />
<labelText labelid="447" fontsize="11" fontstyle="bold" x="10" y="80" width="$once{ parent.width-20 }" />
@@ -505,7 +476,7 @@
Initialize the default settings for cam and resolution and attach the camera
after we have made sure the values are there one time
-->
- <method name="initItemsAndDefaultAttachCamera">
+ <method name="initItems">
<![CDATA[
//fill list of Cameras
var cameras = Camera.names;
@@ -533,21 +504,20 @@
var avstored = getStoredProp("avstored");
- if (availableSettings.getItem(avstored) != null) {
+ if ((isSyncUpdate || standalone) && availableSettings.getItem(avstored) != null) {
+ //get stored item
availableSettings.selectItem(avstored);
+ } else if (availableSettings.getItem(parent.currentClient.avsettings) != null) {
+ availableSettings.selectItem(parent.currentClient.avsettings);
} else {
availableSettings.selectItemAt(0);
}
//Initialize and set default resolutions combobox
- if ($debug) Debug.write("myConfigSet 1 ", canvas.myConfigSet);
- if ($debug) Debug.write("myConfigSet 2 ", canvas.myConfigSet.getPointer().xpathQuery('config/availableCameraResolutions/resolution'));
- if ($debug) Debug.write("myConfigSet 3 ", canvas.myConfigSet.getPointer().xpathQuery('config/availableCameraResolutions/resolution/'));
- if ($debug) Debug.write("myConfigSet 4 ", canvas.myConfigSet.getPointer().xpathQuery('config/availableCameraResolutions/resolution/*'));
-
- this.executeAttachCamera = true;
-
- this.attachCamera();
+ //if ($debug) Debug.write("myConfigSet 1 ", canvas.myConfigSet);
+ //if ($debug) Debug.write("myConfigSet 2 ", canvas.myConfigSet.getPointer().xpathQuery('config/availableCameraResolutions/resolution'));
+ //if ($debug) Debug.write("myConfigSet 3 ", canvas.myConfigSet.getPointer().xpathQuery('config/availableCameraResolutions/resolution/'));
+ //if ($debug) Debug.write("myConfigSet 4 ", canvas.myConfigSet.getPointer().xpathQuery('config/availableCameraResolutions/resolution/*'));
]]>
</method>
@@ -584,14 +554,14 @@
</method>
<method name="cleanVideos">
- if (_video == undefined) return;
- //make sure stop and clear is called, as the _stop method does not work for all
- //videoviews in the device settings.
- _video.content._publisher._chatvideoinner._videostream._stop();
- _video.content._viewer._chatvideoinner._videostream._stop();
- _video.content._publisher._chatvideoinner._videostream.clear();
- _video.content._viewer._chatvideoinner._videostream.clear();
- if ($debug) Debug.write("Cleaned up videos and free resources");
+ if (_video == undefined) return;
+ //make sure stop and clear is called, as the _stop method does not work for all
+ //videoviews in the device settings.
+ _video.content._publisher._chatvideoinner._videostream._stop();
+ _video.content._viewer._chatvideoinner._videostream._stop();
+ _video.content._publisher._chatvideoinner._videostream.clear();
+ _video.content._viewer._chatvideoinner._videostream.clear();
+ if ($debug) Debug.write("Cleaned up videos and free resources");
</method>
<labelText name="availableCamsLabel" labelid="52" fontsize="11" x="10" y="140" width="$once{ parent.width-20 }" />
@@ -604,16 +574,16 @@
<labelText name="availableMicsLabel" labelid="53" fontsize="11" x="10" y="180" width="$once{ parent.width-20 }" />
<resetCombobox fontsize="11" name="availableMics" x="10" y="200" width="280" editable="false" />
- <labelText name="infoTextNoAV" labelid="452" multiline="true" width="280"
- fontsize="11" x="10" y="130" visibility="hidden" />
-
+ <labelText name="infoTextNoAV" labelid="452" multiline="true" width="280"
+ fontsize="11" x="10" y="130" visibility="hidden" />
+
<labelText name="availibleResolutionsLabel" labelid="1429"
fontsize="11" x="10" y="224" width="$once{ parent.width-20 }" />
-
+
<view name="availibleResolutionsWarning" x="272" y="224"
resource="warning_icon_popup_devices_rsc" clickable="true">
<labelTooltip multiline="true" labelid="1430" />
- </view>
+ </view>
<resetCombobox fontsize="11" name="availibleResolutions" x="10" shownitems="10"
y="244" width="280" editable="false">
@@ -690,8 +660,7 @@
</textlistitem>
</resetCombobox>
- <simpleLabelButton name="_btnStartRecording" labelid="775"
- width="140" x="150" y="280" height="28">
+ <simpleLabelButton name="_btnStartRecording" labelid="775" width="140" x="150" y="280" height="28">
<handler name="onclick">
parent._level_meter.startLevel();
parent.doStartRecording();
@@ -701,7 +670,6 @@
<view x="340" y="60" name="_video" clip="true"
width="${ parent.width-this.x-10 }" height="${ parent.height-260 }">
<view name="content">
-
<videoObjectTestBroadcast name="_publisher"
width="${ parent.parent.parent.cam_default_width }"
height="${ parent.parent.parent.cam_default_height }">
@@ -731,27 +699,23 @@
<view name="_text" x="340" y="60" width="240" height="180" visibility="hidden">
- <text name="_info" resize="true" bgcolor="0xFFFFFF" align="right"
- fontsize="12" fontstyle="bold" />
+ <text name="_info" resize="true" bgcolor="0xFFFFFF" align="right" fontsize="12" fontstyle="bold" />
</view>
- <simpleLabelButton name="_play" y="${ parent.height-166 }" x="490" enabled="false"
- width="90" labelid="764" >
+ <simpleLabelButton name="_play" y="${ parent.height-166 }" x="490" enabled="false" width="90" labelid="764">
<handler name="onclick">
parent.doPlay();
</handler>
</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 -->
<attribute name="_leveldel" value="$once{new LzDelegate(this, '_updateLevel')}"/>
<method name="_updateLevel" args="no">
<![CDATA[
- if (parent._video.content._publisher._chatvideoinner._videostream.micro == null)
- {
+ if (parent._video.content._publisher._chatvideoinner._videostream.micro == null) {
return;
}
this.setNewLevel(parent._video.content._publisher._chatvideoinner._videostream.micro.activityLevel);
@@ -784,7 +748,7 @@
<view y="${ parent.height-98 }" resource="test_setup_info_rsc" x="16" />
<labelText fontstyle="bold" labelid="765" x="39" y="${ parent.height-100 }"
- width="${ parent.width-50 }" multiline="true" />
+ width="${ parent.width-50 }" multiline="true" />
<!-- Remember Me -->
<labelCheckbox name="holddatainSO" labelid="762" x="10" y="${ parent.height-20 }" visible="${ !parent.standalone }" >
@@ -804,21 +768,11 @@
</handler>
</labelCheckbox>
- <simpleLabelButton fontsize="11" visible="${ !parent.standalone && canvas.isInterview }" labelid="54" x="${ parent.width-220 }"
- y="${ parent.height-50 }" width="100">
- <handler name="onclick">
- parent.cleanVideos();
- this.parent.storelocaldata();
- this.parent.chosenCam = parent.availableCams.getValue();
- this.parent.chosenMic = parent.availableMics.getValue();
- this.parent.chosenSetting = parent.availableSettings.getValue();
- this.parent.remoteMessage = new Array();
- this.parent.remoteMessage[0] = 'avsettings';
- this.parent.remoteMessage[1] = "0";
- this.parent.remoteMessage[2] = this.parent.chosenSetting;
- this.parent.getBroadCastId.doCall();
- </handler>
- </simpleLabelButton>
+ <method name="storeChosen">
+ chosenCam = availableCams.getValue();
+ chosenMic = availableMics.getValue();
+ chosenSetting = availableSettings.getValue();
+ </method>
<simpleLabelButton fontsize="11" visible="${ !parent.standalone && canvas.isInterview }" labelid="918" x="${ parent.width-110 }"
y="${ parent.height-50 }" width="100">
@@ -828,30 +782,15 @@
</handler>
</simpleLabelButton>
- <simpleLabelButton fontsize="11" visible="${ !parent.standalone && !canvas.isInterview }" labelid="761" width="160" x="${ parent.width-170 }"
- y="${ parent.height-50 }" height="28">
- <handler name="onclick">
- parent.cleanVideos();
- this.parent.storelocaldata();
- this.parent.chosenCam = parent.availableCams.getValue();
- this.parent.chosenMic = parent.availableMics.getValue();
- this.parent.chosenSetting = parent.availableSettings.getValue();
- this.parent.remoteMessage = new Array();
- this.parent.remoteMessage[0] = 'avsettings';
- this.parent.remoteMessage[1] = "0";
- this.parent.remoteMessage[2] = this.parent.chosenSetting;
- this.parent.getBroadCastId.doCall();
- </handler>
- </simpleLabelButton>
-
<simpleLabelButton fontsize="11" visible="${ parent.standalone }" labelid="144" width="160" x="${ parent.width-170 }"
y="${ parent.height-50 }" height="28">
<handler name="onclick">
- //parent.cleanVideos();
- this.parent.storelocaldata();
- //new lz.labelerrorPopup(this.parent, {errorlabelid: 'save.success', labelid: '203'});
+ parent.cleanVideos();
+ parent.storelocaldata();
+ parent.storeChosen();
+ parent.close();
</handler>
</simpleLabelButton>
</class>
-
+
</library>
Modified: openmeetings/application/branches/3.2.x/openmeetings-flash/src/main/swf/video/library.lzx
URL: http://svn.apache.org/viewvc/openmeetings/application/branches/3.2.x/openmeetings-flash/src/main/swf/video/library.lzx?rev=1762732&r1=1762731&r2=1762732&view=diff
==============================================================================
--- openmeetings/application/branches/3.2.x/openmeetings-flash/src/main/swf/video/library.lzx (original)
+++ openmeetings/application/branches/3.2.x/openmeetings-flash/src/main/swf/video/library.lzx Thu Sep 29 03:05:52 2016
@@ -59,7 +59,6 @@
<!-- APL author sebawagner -->
<resource name="lz_recorder_play" src="resources/webstart_play.png" />
- <include href="changeDevice.lzx" />
<include href="videoUserProfilePicSWF10.lzx" />
<include href="editRecordStreamSWF10.lzx" />
<include href="baseVideoObject.lzx" />
Modified: openmeetings/application/branches/3.2.x/openmeetings-flash/src/main/swf/video/videoObjectPlayBroadcast.lzx
URL: http://svn.apache.org/viewvc/openmeetings/application/branches/3.2.x/openmeetings-flash/src/main/swf/video/videoObjectPlayBroadcast.lzx?rev=1762732&r1=1762731&r2=1762732&view=diff
==============================================================================
--- openmeetings/application/branches/3.2.x/openmeetings-flash/src/main/swf/video/videoObjectPlayBroadcast.lzx (original)
+++ openmeetings/application/branches/3.2.x/openmeetings-flash/src/main/swf/video/videoObjectPlayBroadcast.lzx Thu Sep 29 03:05:52 2016
@@ -1,14 +1,23 @@
<?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>
<!--- Contains no microphone or camera Object, this view can only subscribe
@@ -53,8 +62,7 @@
<handler name="oninit">
this.r.setAttribute('frame',5);
- this.initH =
- this.height;
+ this.initH = this.height;
this.initW = this.width;
</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=1762732&r1=1762731&r2=1762732&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 Thu Sep 29 03:05:52 2016
@@ -26,10 +26,8 @@
<handler name="oninit">
<![CDATA[
- var extra = value.sipTransport ? "&parentPath=../default&moduleName=videoconf1"
- : '&parentPath=&remoteUserid='+this.value.userId;
-
- this._userpic.setAttribute('src', canvas.getPictureUrl(value.picture_uri, extra));
+ if ($debug) Debug.write("setUserAVSettings", this);
+ this._userpic.setAttribute('src', canvas.getPictureUrl(value.userId, value.picture_uri));
]]>
</handler>
<omImage name="_userpic" stretches="both" width="${parent.width}" height="${parent.height}" />
Modified: openmeetings/application/branches/3.2.x/openmeetings-web/src/main/java/org/apache/openmeetings/web/app/Application.java
URL: http://svn.apache.org/viewvc/openmeetings/application/branches/3.2.x/openmeetings-web/src/main/java/org/apache/openmeetings/web/app/Application.java?rev=1762732&r1=1762731&r2=1762732&view=diff
==============================================================================
--- openmeetings/application/branches/3.2.x/openmeetings-web/src/main/java/org/apache/openmeetings/web/app/Application.java (original)
+++ openmeetings/application/branches/3.2.x/openmeetings-web/src/main/java/org/apache/openmeetings/web/app/Application.java Thu Sep 29 03:05:52 2016
@@ -39,6 +39,7 @@ import java.util.concurrent.ConcurrentHa
import org.apache.openmeetings.IApplication;
import org.apache.openmeetings.core.remote.MainService;
+import org.apache.openmeetings.core.remote.red5.ScopeApplicationAdapter;
import org.apache.openmeetings.db.dao.basic.ConfigurationDao;
import org.apache.openmeetings.db.dao.label.LabelDao;
import org.apache.openmeetings.db.dao.user.UserDao;
@@ -49,6 +50,7 @@ import org.apache.openmeetings.db.entity
import org.apache.openmeetings.db.entity.user.User;
import org.apache.openmeetings.db.entity.user.User.Type;
import org.apache.openmeetings.util.InitializationContainer;
+import org.apache.openmeetings.web.app.Client.Activity;
import org.apache.openmeetings.web.pages.AccessDeniedPage;
import org.apache.openmeetings.web.pages.ActivatePage;
import org.apache.openmeetings.web.pages.HashPage;
@@ -232,8 +234,24 @@ public class Application extends Authent
rcl.setIsSuperModerator(client.hasRight(Right.superModerator));
rcl.setIsMod(client.hasRight(Right.moderator));
rcl.setIsBroadcasting(client.hasRight(Right.audio));
- rcl.setCanVideo(client.hasRight(Right.video));
+ rcl.setCanVideo(client.hasRight(Right.video) && client.hasActivity(Activity.broadcastVideo));
rcl.setCanDraw(client.hasRight(Right.whiteBoard));
+ if (client.hasActivity(Activity.broadcastAudio) || client.hasActivity(Activity.broadcastVideo)) {
+ rcl.setIsBroadcasting(true);
+ rcl.setBroadCastID(ScopeApplicationAdapter.nextBroadCastId());
+ StringBuilder sb = new StringBuilder();
+ if (client.hasActivity(Activity.broadcastAudio)) {
+ sb.append('a');
+ }
+ if (client.hasActivity(Activity.broadcastVideo)) {
+ sb.append('v');
+ }
+ rcl.setAvsettings(sb.toString());
+ } else {
+ rcl.setAvsettings("n");
+ rcl.setIsBroadcasting(false);
+ rcl.setBroadCastID(-1L);
+ }
}
return rcl;
}
Modified: openmeetings/application/branches/3.2.x/openmeetings-web/src/main/java/org/apache/openmeetings/web/app/Client.java
URL: http://svn.apache.org/viewvc/openmeetings/application/branches/3.2.x/openmeetings-web/src/main/java/org/apache/openmeetings/web/app/Client.java?rev=1762732&r1=1762731&r2=1762732&view=diff
==============================================================================
--- openmeetings/application/branches/3.2.x/openmeetings-web/src/main/java/org/apache/openmeetings/web/app/Client.java (original)
+++ openmeetings/application/branches/3.2.x/openmeetings-web/src/main/java/org/apache/openmeetings/web/app/Client.java Thu Sep 29 03:05:52 2016
@@ -39,10 +39,11 @@ public class Client implements IDataProv
private static final long serialVersionUID = 1L;
public enum Activity {
- broadcast
+ broadcastAudio //sends Audio to the room
+ , broadcastVideo //sends Video to the room
, share
, record
- , publish
+ , publish //sends A/V to external server
, muted
, exclusive
}
Modified: openmeetings/application/branches/3.2.x/openmeetings-web/src/main/java/org/apache/openmeetings/web/room/RoomPanel.java
URL: http://svn.apache.org/viewvc/openmeetings/application/branches/3.2.x/openmeetings-web/src/main/java/org/apache/openmeetings/web/room/RoomPanel.java?rev=1762732&r1=1762731&r2=1762732&view=diff
==============================================================================
--- openmeetings/application/branches/3.2.x/openmeetings-web/src/main/java/org/apache/openmeetings/web/room/RoomPanel.java (original)
+++ openmeetings/application/branches/3.2.x/openmeetings-web/src/main/java/org/apache/openmeetings/web/room/RoomPanel.java Thu Sep 29 03:05:52 2016
@@ -21,6 +21,7 @@ package org.apache.openmeetings.web.room
import static org.apache.openmeetings.util.OpenmeetingsVariables.webAppRootKey;
import static org.apache.openmeetings.web.app.Application.addUserToRoom;
import static org.apache.openmeetings.web.app.Application.getBean;
+import static org.apache.openmeetings.web.app.Application.getOnlineClient;
import static org.apache.openmeetings.web.app.Application.getRoomClients;
import static org.apache.openmeetings.web.app.WebSession.getDateFormat;
import static org.apache.openmeetings.web.app.WebSession.getUserId;
@@ -31,6 +32,7 @@ import java.net.MalformedURLException;
import java.net.URL;
import java.util.Calendar;
+import org.apache.directory.api.util.Strings;
import org.apache.openmeetings.core.remote.ConferenceLibrary;
import org.apache.openmeetings.core.remote.red5.ScopeApplicationAdapter;
import org.apache.openmeetings.db.dao.basic.ConfigurationDao;
@@ -280,14 +282,31 @@ public class RoomPanel extends BasePanel
}
break;
case recordingStoped:
- //TODO check recordingUser == ((TextRoomMessage)m).getText();
- recordingUser = null;
- menu.update(handler);
+ {
+ String uid = ((TextRoomMessage)m).getText();
+ if (Strings.isEmpty(uid) || !uid.equals(recordingUser)) {
+ log.error("Not existing/BAD user has stopped recording {} != {} !!!!", uid, recordingUser);
+ }
+ recordingUser = null;
+ menu.update(handler);
+ Client c = getOnlineClient(uid);
+ if (c == null) {
+ log.error("Not existing user has stopped recording {} !!!!", uid);
+ return;
+ }
+ c.getActivities().remove(Client.Activity.record);
+ }
break;
case recordingStarted:
{
recordingUser = ((TextRoomMessage)m).getText();
menu.update(handler);
+ Client c = getOnlineClient(recordingUser);
+ if (c == null) {
+ log.error("Not existing user has started recording {} !!!!", recordingUser);
+ return;
+ }
+ c.getActivities().add(Client.Activity.record);
}
break;
case sharingStoped:
Modified: openmeetings/application/branches/3.2.x/openmeetings-web/src/main/java/org/apache/openmeetings/web/room/sidebar/RoomSidebar.java
URL: http://svn.apache.org/viewvc/openmeetings/application/branches/3.2.x/openmeetings-web/src/main/java/org/apache/openmeetings/web/room/sidebar/RoomSidebar.java?rev=1762732&r1=1762731&r2=1762732&view=diff
==============================================================================
--- openmeetings/application/branches/3.2.x/openmeetings-web/src/main/java/org/apache/openmeetings/web/room/sidebar/RoomSidebar.java (original)
+++ openmeetings/application/branches/3.2.x/openmeetings-web/src/main/java/org/apache/openmeetings/web/room/sidebar/RoomSidebar.java Thu Sep 29 03:05:52 2016
@@ -27,9 +27,11 @@ import static org.apache.wicket.ajax.att
import java.util.ArrayList;
import java.util.Arrays;
+import org.apache.openmeetings.db.entity.room.Room;
import org.apache.openmeetings.db.entity.room.Room.Right;
import org.apache.openmeetings.db.entity.room.Room.RoomElement;
import org.apache.openmeetings.web.app.Client;
+import org.apache.openmeetings.web.app.Client.Activity;
import org.apache.openmeetings.web.room.RoomPanel;
import org.apache.wicket.ajax.AbstractDefaultAjaxBehavior;
import org.apache.wicket.ajax.AjaxRequestTarget;
@@ -55,10 +57,13 @@ public class RoomSidebar extends Panel {
private static final long serialVersionUID = 1L;
private static final Logger log = Red5LoggerFactory.getLogger(RoomSidebar.class, webAppRootKey);
public static final String FUNC_TOGGLE_RIGHT = "toggleRight";
+ public static final String FUNC_TOGGLE_ACTIVITY = "toggleActivity";
public static final String FUNC_ACTION = "roomAction";
public static final String PARAM_ACTION = "action";
+ public static final String PARAM_ACTIVITY = "activity";
public static final String PARAM_RIGHT = "right";
public static final String PARAM_UID = "uid";
+ public static final String PARAM_POD = "pod";
private final RoomPanel room;
private final TabbedPanel tabs;
private final ITab userTab;
@@ -67,6 +72,11 @@ public class RoomSidebar extends Panel {
private final RoomFilePanel roomFiles;
private final SelfIconsPanel selfRights;
private boolean showFiles;
+ public enum Pod {
+ none
+ , right
+ , left
+ };
private final ListView<Client> users = new ListView<Client>("user", new ArrayList<Client>()) {
private static final long serialVersionUID = 1L;
@@ -115,7 +125,35 @@ public class RoomSidebar extends Panel {
room.requestRight(target, right);
}
} catch (Exception e) {
- log.error("Unexpected exception while processing activity action", e);
+ log.error("Unexpected exception while toggle 'right'", e);
+ }
+ }
+ };
+ private final AbstractDefaultAjaxBehavior toggleActivity = new AbstractDefaultAjaxBehavior() {
+ private static final long serialVersionUID = 1L;
+
+ @Override
+ protected void respond(AjaxRequestTarget target) {
+ try {
+ String uid = getRequest().getRequestParameters().getParameterValue(PARAM_UID).toString();
+ if (Strings.isEmpty(uid)) {
+ return;
+ }
+ Activity a = Activity.valueOf(getRequest().getRequestParameters().getParameterValue(PARAM_ACTIVITY).toString());
+ Client c = getOnlineClient(uid);
+ if (c == null) {
+ return;
+ }
+ if (activityAllowed(c, a, room.getRoom())) {
+ if (c.hasActivity(a)) {
+ c.getActivities().remove(a);
+ } else {
+ c.getActivities().add(a);
+ }
+ room.broadcast(target, c);
+ }
+ } catch (Exception e) {
+ log.error("Unexpected exception while toggle 'activity'", e);
}
}
};
@@ -165,13 +203,14 @@ public class RoomSidebar extends Panel {
roomFiles = new RoomFilePanel("tree", room);
selfRights = new SelfIconsPanel("icons", room.getClient(), room);
add(upload = new UploadDialog("upload", room, roomFiles));
- add(toggleRight, action);
+ add(toggleRight, toggleActivity, action);
}
@Override
public void renderHead(IHeaderResponse response) {
super.renderHead(response);
response.render(new PriorityHeaderItem(JavaScriptHeaderItem.forScript(getNamedFunction(FUNC_TOGGLE_RIGHT, toggleRight, explicit(PARAM_RIGHT), explicit(PARAM_UID)), FUNC_TOGGLE_RIGHT)));
+ response.render(new PriorityHeaderItem(JavaScriptHeaderItem.forScript(getNamedFunction(FUNC_TOGGLE_ACTIVITY, toggleActivity, explicit(PARAM_ACTIVITY), explicit(PARAM_UID), explicit(PARAM_POD)), FUNC_TOGGLE_ACTIVITY)));
response.render(new PriorityHeaderItem(JavaScriptHeaderItem.forScript(getNamedFunction(FUNC_ACTION, action, explicit(PARAM_ACTION), explicit(PARAM_UID)), FUNC_ACTION)));
}
@@ -223,4 +262,25 @@ public class RoomSidebar extends Panel {
public void showUpload(IPartialPageRequestHandler handler) {
upload.open(handler);
}
+
+ public static boolean activityAllowed(Client c, Activity a, Room room) {
+ switch (a) {
+ case broadcastVideo:
+ {
+ if (room.isAudioOnly()) {
+ return false;
+ }
+ if (c.hasRight(Right.moderator)) {
+ return true;
+ }
+ for (Right r : new Right[]{Right.video}) {
+ if (!c.hasRight(r)) {
+ return false;
+ }
+ }
+ }
+ break;
+ }
+ return false;
+ }
}
Modified: openmeetings/application/branches/3.2.x/openmeetings-web/src/main/java/org/apache/openmeetings/web/room/sidebar/SelfIconsPanel.html
URL: http://svn.apache.org/viewvc/openmeetings/application/branches/3.2.x/openmeetings-web/src/main/java/org/apache/openmeetings/web/room/sidebar/SelfIconsPanel.html?rev=1762732&r1=1762731&r2=1762732&view=diff
==============================================================================
--- openmeetings/application/branches/3.2.x/openmeetings-web/src/main/java/org/apache/openmeetings/web/room/sidebar/SelfIconsPanel.html (original)
+++ openmeetings/application/branches/3.2.x/openmeetings-web/src/main/java/org/apache/openmeetings/web/room/sidebar/SelfIconsPanel.html Thu Sep 29 03:05:52 2016
@@ -21,5 +21,6 @@
<html xmlns:wicket="http://wicket.apache.org">
<wicket:extend>
<span wicket:id="settings"></span>
+ <span wicket:id="cam"></span>
</wicket:extend>
</html>
Modified: openmeetings/application/branches/3.2.x/openmeetings-web/src/main/java/org/apache/openmeetings/web/room/sidebar/SelfIconsPanel.java
URL: http://svn.apache.org/viewvc/openmeetings/application/branches/3.2.x/openmeetings-web/src/main/java/org/apache/openmeetings/web/room/sidebar/SelfIconsPanel.java?rev=1762732&r1=1762731&r2=1762732&view=diff
==============================================================================
--- openmeetings/application/branches/3.2.x/openmeetings-web/src/main/java/org/apache/openmeetings/web/room/sidebar/SelfIconsPanel.java (original)
+++ openmeetings/application/branches/3.2.x/openmeetings-web/src/main/java/org/apache/openmeetings/web/room/sidebar/SelfIconsPanel.java Thu Sep 29 03:05:52 2016
@@ -21,15 +21,18 @@ package org.apache.openmeetings.web.room
import org.apache.openmeetings.web.app.Client;
import org.apache.openmeetings.web.room.RoomPanel;
import org.apache.openmeetings.web.room.sidebar.icon.SettingsIcon;
+import org.apache.openmeetings.web.room.sidebar.icon.activity.CamActivityIcon;
import org.apache.wicket.core.request.handler.IPartialPageRequestHandler;
public class SelfIconsPanel extends ClientIconsPanel {
private static final long serialVersionUID = 1L;
private final SettingsIcon settings;
+ private final CamActivityIcon cam;
public SelfIconsPanel(String id, Client client, RoomPanel room) {
super(id, client, room);
- add(settings = new SettingsIcon("settings", client, room));
+ add(settings = new SettingsIcon("settings", client, room)
+ , cam = new CamActivityIcon("cam", client, room));
}
@Override
@@ -42,5 +45,6 @@ public class SelfIconsPanel extends Clie
public void update(IPartialPageRequestHandler handler) {
super.update(handler);
settings.update(handler);
+ cam.update(handler);
}
}
Modified: openmeetings/application/branches/3.2.x/openmeetings-web/src/main/java/org/apache/openmeetings/web/room/sidebar/icon/SettingsIcon.java
URL: http://svn.apache.org/viewvc/openmeetings/application/branches/3.2.x/openmeetings-web/src/main/java/org/apache/openmeetings/web/room/sidebar/icon/SettingsIcon.java?rev=1762732&r1=1762731&r2=1762732&view=diff
==============================================================================
--- openmeetings/application/branches/3.2.x/openmeetings-web/src/main/java/org/apache/openmeetings/web/room/sidebar/icon/SettingsIcon.java (original)
+++ openmeetings/application/branches/3.2.x/openmeetings-web/src/main/java/org/apache/openmeetings/web/room/sidebar/icon/SettingsIcon.java Thu Sep 29 03:05:52 2016
@@ -42,6 +42,6 @@ public class SettingsIcon extends Client
@Override
protected String getScript() {
- return String.format("$('#lzapp').showAvSettings(%s);", Room.Type.interview == room.getRoom().getType());
+ return String.format("document.getElementById('lzapp').showAvSettings(%s);", Room.Type.interview == room.getRoom().getType());
}
}
Added: openmeetings/application/branches/3.2.x/openmeetings-web/src/main/java/org/apache/openmeetings/web/room/sidebar/icon/activity/CamActivityIcon.java
URL: http://svn.apache.org/viewvc/openmeetings/application/branches/3.2.x/openmeetings-web/src/main/java/org/apache/openmeetings/web/room/sidebar/icon/activity/CamActivityIcon.java?rev=1762732&view=auto
==============================================================================
--- openmeetings/application/branches/3.2.x/openmeetings-web/src/main/java/org/apache/openmeetings/web/room/sidebar/icon/activity/CamActivityIcon.java (added)
+++ openmeetings/application/branches/3.2.x/openmeetings-web/src/main/java/org/apache/openmeetings/web/room/sidebar/icon/activity/CamActivityIcon.java Thu Sep 29 03:05:52 2016
@@ -0,0 +1,43 @@
+/*
+ * 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.
+ */
+package org.apache.openmeetings.web.room.sidebar.icon.activity;
+
+import org.apache.openmeetings.web.app.Client;
+import org.apache.openmeetings.web.app.Client.Activity;
+import org.apache.openmeetings.web.room.RoomPanel;
+
+public class CamActivityIcon extends RoomActivityIcon {
+ private static final long serialVersionUID = 1L;
+
+ public CamActivityIcon(String id, Client client, RoomPanel room) {
+ super(id, client, Activity.broadcastVideo, room);
+ mainCssClass = "activity cam ";
+ }
+
+ @Override
+ protected String getTitle() {
+ return getString("687");
+ }
+
+ @Override
+ protected boolean isClickable() {
+ return true;
+ }
+
+}
Added: openmeetings/application/branches/3.2.x/openmeetings-web/src/main/java/org/apache/openmeetings/web/room/sidebar/icon/activity/RoomActivityIcon.java
URL: http://svn.apache.org/viewvc/openmeetings/application/branches/3.2.x/openmeetings-web/src/main/java/org/apache/openmeetings/web/room/sidebar/icon/activity/RoomActivityIcon.java?rev=1762732&view=auto
==============================================================================
--- openmeetings/application/branches/3.2.x/openmeetings-web/src/main/java/org/apache/openmeetings/web/room/sidebar/icon/activity/RoomActivityIcon.java (added)
+++ openmeetings/application/branches/3.2.x/openmeetings-web/src/main/java/org/apache/openmeetings/web/room/sidebar/icon/activity/RoomActivityIcon.java Thu Sep 29 03:05:52 2016
@@ -0,0 +1,57 @@
+/*
+ * 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.
+ */
+package org.apache.openmeetings.web.room.sidebar.icon.activity;
+
+import static org.apache.openmeetings.web.room.sidebar.RoomSidebar.FUNC_TOGGLE_ACTIVITY;
+
+import org.apache.openmeetings.web.app.Client;
+import org.apache.openmeetings.web.app.Client.Activity;
+import org.apache.openmeetings.web.room.RoomPanel;
+import org.apache.openmeetings.web.room.sidebar.RoomSidebar;
+import org.apache.openmeetings.web.room.sidebar.RoomSidebar.Pod;
+import org.apache.openmeetings.web.room.sidebar.icon.ClientIcon;
+
+public abstract class RoomActivityIcon extends ClientIcon {
+ private static final long serialVersionUID = 1L;
+ private static final String CLS_ENABLED = "enabled ";
+ protected final Activity activity;
+ protected final Pod pod = Pod.none;
+
+ public RoomActivityIcon(String id, Client client, Activity activity, RoomPanel room) {
+ super(id, client, room);
+ this.activity = activity;
+ }
+
+ @Override
+ protected String getScript() {
+ return String.format("%s('%s', '%s', '%s');", FUNC_TOGGLE_ACTIVITY, activity.name(), client.getUid(), pod.name());
+ }
+
+ protected boolean visible() {
+ return RoomSidebar.activityAllowed(client, activity, room.getRoom());
+ }
+
+ @Override
+ protected void internalUpdate() {
+ setVisible(visible());
+ if (client.hasActivity(activity)) {
+ cssClass.append(CLS_ENABLED);
+ }
+ }
+}
Modified: openmeetings/application/branches/3.2.x/openmeetings-web/src/main/webapp/css/room.css
URL: http://svn.apache.org/viewvc/openmeetings/application/branches/3.2.x/openmeetings-web/src/main/webapp/css/room.css?rev=1762732&r1=1762731&r2=1762732&view=diff
==============================================================================
--- openmeetings/application/branches/3.2.x/openmeetings-web/src/main/webapp/css/room.css (original)
+++ openmeetings/application/branches/3.2.x/openmeetings-web/src/main/webapp/css/room.css Thu Sep 29 03:05:52 2016
@@ -225,6 +225,12 @@
.settings.ui-icon {
background-image: url(images/settings.png);
}
+.activity.cam.ui-icon {
+ background-image: url(images/webcam_enable.png);
+}
+.activity.cam.enabled.ui-icon {
+ background-image: url(images/webcam_disable.png);
+}
.room.sidebar.left .tabs, .room.sidebar.left .tabs #utab, .room.sidebar.left .tabs #ftab {
padding: 0;
}