Fixes issue #70 - Invite others reports null when pressed too early.

This commit is contained in:
yanas 2014-05-21 15:12:51 +02:00
parent e6aba30c09
commit 4d0c74879a
1 changed files with 16 additions and 12 deletions

28
app.js
View File

@ -1213,7 +1213,6 @@ function buttonClick(id, classname) {
* @param messageString the text of the message * @param messageString the text of the message
*/ */
function openMessageDialog(titleString, messageString) { function openMessageDialog(titleString, messageString) {
console.log("OPEN MESSAGE DIALOG");
$.prompt(messageString, $.prompt(messageString,
{ {
title: titleString, title: titleString,
@ -1288,17 +1287,22 @@ function openLockDialog() {
* Opens the invite link dialog. * Opens the invite link dialog.
*/ */
function openLinkDialog() { function openLinkDialog() {
$.prompt('<input id="inviteLinkRef" type="text" value="' + if (roomUrl == null)
encodeURI(roomUrl) + '" onclick="this.select();" readonly>', openMessageDialog( "Invite others",
{ "Your conference is currently being created."
title: "Share this link with everyone you want to invite", + " Please try again in a few seconds.");
persistent: false, else
buttons: { "Cancel": false}, $.prompt('<input id="inviteLinkRef" type="text" value="' +
loaded: function (event) { encodeURI(roomUrl) + '" onclick="this.select();" readonly>',
document.getElementById('inviteLinkRef').select(); {
} title: "Share this link with everyone you want to invite",
} persistent: false,
); buttons: { "Cancel": false},
loaded: function (event) {
document.getElementById('inviteLinkRef').select();
}
}
);
} }
/** /**