Hey out there! I need urgent help. I would be very thankful for helping solving my problem.
I am implementing a MVC Application for an online group experiment. In the experiment groups of three members must solve tasks together within a google docs (first iframe) communicating only via chat (jitsi meet API).
The problem is, that the jitsi chat always steals focus, so that typing into the google docs is not possible. Tried to set focus again and again on the google doc with kind of that code:
function setFocusThickboxIframe() {
var iframe = $("#TB_iframeContent")[0];
iframe.contentWindow.focus();
}
$(document).ready(function(){
$("#id_cmd_open").click(function(){
/*
run thickbox code here to open lightbox,
like tb_show("google this!", "http://www.google.com");
*/
setTimeout(setFocusThickboxIframe, 100);
return false;
});
});
But that does not work. Jitsi focus is “stronger” - unfortunately. Any ideas?
Here a screenshot from the online experiment and debugging mode:
Jitsi API integrated as follows:
function registerCommunicationClient() {
//doku: https://github.com/jitsi/jitsi-meet/blob/master/doc/api.md
$.ajax({
type: "GET",
url: "/Experiment/get_CommunicationParameters",
contentType: "application/json; charset=utf-8",
dataType: "json",
success: function (response) {
var domain = "meet.jit.si";
var options = {
roomName: response.communicationID,
width: 400,
parentNode: document.querySelector('#div_Communication_Container'),
height: 900,
configOverwrite: {
disableSuspendVideo: false
},
interfaceConfigOverwrite: {
filmStripOnly: false,
SHOW_JITSI_WATERMARK: false,
MAIN_TOOLBAR_BUTTONS: [],
TOOLBAR_BUTTONS: ['chat'],
INVITE_OPTIONS: []
}
}
if ((response.communicationChannel != 'FaceToFace') && (response.communicationChannel != 'Individual')) {
api = new JitsiMeetExternalAPI(domain, options);
api.executeCommand('displayName', response.nickname);
api.executeCommand('toggleFilmStrip');
if (response.communicationChannel == 'Audio') {
api.executeCommand('toggleVideo');
}
else if (response.communicationChannel == 'Chat') {
api.executeCommand('toggleVideo');
api.executeCommand('toggleAudio');
api.executeCommand('toggleChat');
api.executeCommand('muteEveryone');
}
}
},
failure: function (response) {
alert("Failure in Method registerCommunicationClient() in View Experiment");
},
error: function (response) {
alert("Error in Method registerCommunicationClient() in View Experiment");
}
});
}