This reverts commit 94df500ba6.
This commit is contained in:
Richard Alam 2015-07-24 15:59:42 +00:00
parent 94df500ba6
commit 4b552329d7
5 changed files with 13 additions and 55 deletions

View File

@ -3,9 +3,6 @@ if (!window.console.log) window.console.log = function () { };
function startApplet(IP, useTLS , roomNumber, fullScreen, useSVC2)
{
var deskshareElement = document.getElementById("deskshare");
if (deskshareElement == null) {
console.log("Starting deskshare applet.");
var div = document.createElement("div");
div.id = "deskshare";
@ -24,40 +21,15 @@ function startApplet(IP, useTLS , roomNumber, fullScreen, useSVC2)
"<param name=\"permissions\" value=\"all-permissions\"/>" +
"</applet>";
document.body.appendChild(div);
} else {
console.log("Deskshare applet element already exists.");
var div = document.getElementById("deskshare");
if (div.parentNode) {
// Just rewrite the applet tag to kick off the applet. We don't remove the applet tag
// when desktop sharing is stopped to prevent Firefox (38.0.5) from asking for user permissions
// again resulting in the page reloading. (ralam june 17, 2015)
// https://code.google.com/p/bigbluebutton/issues/detail?id=1953
div.innerHTML =
"<applet code=\"org.bigbluebutton.deskshare.client.DeskShareApplet.class\"" +
"id=\"DeskShareApplet\" width=\"100\" height=\"10\" archive=\"bbb-deskshare-applet-0.9.0.jar\">" +
"<param name=\"ROOM\" value=\"" + roomNumber + "\"/>" +
"<param name=\"IP\" value=\"" + IP + "\"/>" +
"<param name=\"PORT\" value=\"9123\"/>" +
"<param name=\"SCALE\" value=\"0.8\"/>" +
"<param name=\"FULL_SCREEN\" value=\"" + fullScreen + "\"/>" +
"<param name=\"SVC2\" value=\"" + useSVC2 + "\"/>" +
"<param name=\"JavaVersion\" value=\"1.7.0_51\"/>" +
"<param name=\"permissions\" value=\"all-permissions\"/>" +
"</applet>";
}
}
}
function removeFrame () {
var div = document.getElementById("deskshare");
if (div.parentNode) {
// Need to set the innerHTML otherwise the applet will restart in IE.
// see https://code.google.com/p/bigbluebutton/issues/detail?id=1776
// Do NOT remove the applet tag as it makes Firefox (38.0.5) prompt for
// permissions again resulting in the page reloading. (ralam june 17, 2015)
// div.innerHTML = "";
// div.parentNode.removeChild(div);
div.innerHTML = "";
div.parentNode.removeChild(div);
}
}

View File

@ -102,8 +102,6 @@ with BigBlueButton; if not, see <http://www.gnu.org/licenses/>.
[Bindable] private var baseIndex:int;
[Bindable] private var dsOptions:DeskshareOptions;
private var calledStopApplet:Boolean = false;
private function init():void {
dsOptions = new DeskshareOptions();
baseIndex = dsOptions.baseTabIndex;
@ -344,22 +342,13 @@ with BigBlueButton; if not, see <http://www.gnu.org/licenses/>.
closeWindow();
}
private function callStopApplet():void {
if (!calledStopApplet) {
calledStopApplet = true;
trace("Calling stopApplet in callStopApplet()");
ExternalInterface.call("stopApplet");
}
}
private function closeWindow():void {
trace("Calling stopApplet in closeWindow()");
callStopApplet();
ExternalInterface.call("stopApplet");
dispatchEvent(new ShareWindowEvent(ShareWindowEvent.CLOSE));
}
private function restartJava():void {
trace("Calling stopApplet in restartJava()");
callStopApplet();
ExternalInterface.call("stopApplet");
shareScreen(sharingFullScreen);
}

View File

@ -201,9 +201,7 @@ public class DeskShareApplet extends JApplet implements ClientListener {
}
public void onClientStop(ExitCode reason) {
client.stop();
/*
// determine if client is disconnected _PTS_272_
if ( ExitCode.CONNECTION_TO_DESKSHARE_SERVER_DROPPED == reason ){
JFrame pframe = new JFrame("Desktop Sharing Disconneted");
if ( null != pframe ){
@ -217,7 +215,6 @@ public class DeskShareApplet extends JApplet implements ClientListener {
}else{
client.stop();
}
*/
}
}