2011-03-28 05:45:08 +08:00
|
|
|
var blinkTimer = false;
|
|
|
|
var blinking = false;
|
|
|
|
|
|
|
|
var startblink = function(message1, message2)
|
|
|
|
{
|
|
|
|
if(!blinking)
|
|
|
|
{
|
|
|
|
document.title = (document.title == message2)?message1:message2;
|
|
|
|
blinkTimer = window.setTimeout("blinktitle('" + message1 + "', '" + message2 + "', 1)", 500);
|
|
|
|
blinking = true;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
var blinktitle = function(message1, message2)
|
|
|
|
{
|
|
|
|
document.title = (document.title == message2)?message1:message2;
|
|
|
|
blinkTimer = window.setTimeout("blinktitle('" + message1 + "', '" + message2 + "', 1)", 500);
|
|
|
|
}
|
|
|
|
|
|
|
|
var clearblink = function()
|
|
|
|
{
|
|
|
|
blinking = false;
|
|
|
|
if(blinkTimer)
|
|
|
|
{
|
|
|
|
window.clearTimeout(blinkTimer);
|
|
|
|
}
|
|
|
|
document.title = 'BigBlueButton';
|
|
|
|
}
|
|
|
|
|
2012-08-10 02:14:20 +08:00
|
|
|
var i = 1;
|
|
|
|
function addAlert(message){
|
|
|
|
var target = document.getElementById( 'notifications' ),
|
|
|
|
contentDiv = document.createElement( "div" );
|
|
|
|
contentDiv.id = "alertDiv" + i;
|
|
|
|
i++;
|
|
|
|
contentDiv.innerHTML = "<p>" + message + "</p>";
|
|
|
|
contentDiv.style.display = "block";
|
|
|
|
target.appendChild( contentDiv );
|
|
|
|
target.hide();
|
|
|
|
target.show();
|
|
|
|
contentDiv.hide();
|
|
|
|
contentDiv.show();
|
|
|
|
}
|
|
|
|
|
|
|
|
function determineBrowser()
|
|
|
|
{
|
|
|
|
return navigator.appName;
|
|
|
|
}
|