X-Git-Url: https://mop.ddnsfree.com/gitweb/?a=blobdiff_plain;f=web%2Fcommons.js;h=c8573905244f0f2604bf0e8bd65000ccb1d93186;hb=1da3c486582c30adbc3d3055d5bd046427ac7ab3;hp=6281dea30ef6456485514d0ff9f26459ee0c145e;hpb=68fb2c2e1ee1360daf3ac1e7e2edf5a03bb57845;p=brisk.git diff --git a/web/commons.js b/web/commons.js index 6281dea..c857390 100644 --- a/web/commons.js +++ b/web/commons.js @@ -135,10 +135,12 @@ function reset_images() function update_images() { + // if (g_imgct % 10 == 0) alert("g_imgct: "+g_imgct+" xx "+g_preload_img_arr[g_imgct]); $("imgct").innerHTML = "Immagini caricate "+g_preload_imgsz_arr[g_imgct]+"%."; - if (g_imgct < g_preload_img_arr.length) - setTimeout(preload_images, 100, g_preload_img_arr, g_imgct); - g_imgct++; + if (g_imgct+1 < g_preload_img_arr.length) { + g_imgct++; + setTimeout(preload_images, 100, g_preload_img_arr, g_imgct-1); + } // $("imgct").innerHTML += "U"; } @@ -177,7 +179,7 @@ function send_mesg(mesg) var xhr_wr = createXMLHttpRequest(); - xhr_wr.open('GET', 'index_wr.php?sess='+sess+'&mesg='+encodeURIComponent(mesg), true); + xhr_wr.open('GET', 'index_wr.php?sess='+sess+'&mesg='+mesg, true); xhr_wr.onreadystatechange = function() { return; }; xhr_wr.send(null);