Monotone-Parent: e386794fdf815f604f1ca9b4a70b393e9f4fe7e4

Monotone-Revision: eb2f5a8d3d72ba94f994f34666890ef3703e703c

Monotone-Author: wsourdeau@inverse.ca
Monotone-Date: 2006-08-24T18:48:33
Monotone-Branch: ca.inverse.sogo
This commit is contained in:
Wolfgang Sourdeau
2006-08-24 18:48:33 +00:00
parent 742e9c2c98
commit 85fc1c897f
6 changed files with 217 additions and 230 deletions
-60
View File
@@ -176,66 +176,6 @@ function hideInlineAttachmentList(sender) {
e.style.width = "100%";
}
/* ajax contactsFolder handling */
var activeAjaxRequests = 0;
function triggerAjaxRequest(url, callback, userdata) {
var http = createHTTPClient();
activeAjaxRequests += 1;
document.animTimer = setTimeout("checkAjaxRequestsState();", 200);
if (http) {
http.onreadystatechange
= function() {
try {
if (http.readyState == 4
&& activeAjaxRequests > 0) {
if (!http.aborted) {
http.callbackData = userdata;
callback(http);
}
activeAjaxRequests -= 1;
checkAjaxRequestsState();
}
}
catch( e ) {
activeAjaxRequests -= 1;
checkAjaxRequestsState();
alert('AJAX Request, Caught Exception: ' + e.description);
}
};
http.url = url;
http.open("GET", url, true);
http.send("");
}
return http;
}
function checkAjaxRequestsState()
{
if (activeAjaxRequests > 0
&& !document.busyAnim) {
var anim = document.createElement("img");
document.busyAnim = anim;
anim.setAttribute("src", ResourcesURL + '/busy.gif');
anim.style.position = "absolute;";
anim.style.top = "2.5em;";
anim.style.right = "1em;";
anim.style.visibility = "hidden;";
anim.style.zindex = "1;";
var folderTree = document.getElementById("toolbar");
folderTree.appendChild(anim);
anim.style.visibility = "visible;";
} else if (activeAjaxRequests == 0
&& document.busyAnim) {
document.busyAnim.parentNode.removeChild(document.busyAnim);
document.busyAnim = null;
}
}
function onContactsFolderTreeItemClick(element)
{
var topNode = document.getElementById('d');