Added Edit Survey loading mask to reduce loading confusing on slow connections.

This commit is contained in:
Kaleb Murphy 2009-03-16 15:59:20 +00:00
parent 38a19674da
commit cc11480d6d
6 changed files with 41 additions and 4 deletions

View file

@ -353,6 +353,7 @@ if (typeof Survey === "undefined") {
}
else {
document.getElementById('questions').style.display = 'inline';
console.log(2);
Survey.Form.addWidgets(qs);
}
lastSection = s.id;
@ -361,6 +362,7 @@ if (typeof Survey === "undefined") {
document.getElementById('headertitle').style.display = 'block';
document.getElementById('headertext').style.display = 'block';
document.getElementById('questions').style.display = 'inline';
console.log(3);
Survey.Form.addWidgets(qs);
}
},

View file

@ -6,6 +6,7 @@ Survey.Comm = new function(){
var callMade = 0;
var request = function(sUrl,callback,postData){
YAHOO.util.Dom.setStyle('mask-all','display','block');
if(callMade == 1){
alert("Waiting on previous request");
}else{
@ -15,6 +16,7 @@ Survey.Comm = new function(){
}
this.callback = {
success:function(o){
YAHOO.util.Dom.setStyle('mask-all','display','none');
callMade = 0;
Survey.Data.loadData(YAHOO.lang.JSON.parse(o.responseText));
},

View file

@ -1,4 +1,38 @@
#loading-mask {
position: absolute;
left: 0;
top: 0;
width: 100%;
height: 100%;
z-index: 20000;
background-color: white;
opacity:0.6;
filter:alpha(opacity=60);
}
#loading {
position: absolute;
left: 50%;
top: 50%;
padding: 2px;
z-index: 20001;
height: auto;
margin: -35px 0 0 -30px;
}
#loading .loading-indicator {
background: url(/extras/yui/rel_interstitial_loading.gif) no-repeat;
color: #555;
font: bold 13px tahoma,arial,helvetica;
padding: 18px 80px;
margin: 0;
text-align: center;
height: auto;
z-index: 20002;
}
div.testarea {
width: 200px;
height: 100px;