Fix popup loading indicator sometimes not closing after load (#4169)

Fixes #4168. Credit to @drmzio
This commit is contained in:
Daniel Ramirez 2019-03-25 09:07:33 -07:00 committed by Luke Towers
parent 8606db9e77
commit cb24d817ad
2 changed files with 2 additions and 2 deletions

View File

@ -254,7 +254,7 @@
setTimeout(function(){ self.$backdrop.addClass('loading'); }, 100)
}
else {
this.$backdrop.removeClass('loading');
setTimeout(function(){ self.$backdrop.removeClass('loading'); }, 100)
}
}

View File

@ -3808,7 +3808,7 @@ this.$backdrop=null}}
Popup.prototype.setLoading=function(val){if(!this.$backdrop)
return;var self=this
if(val){setTimeout(function(){self.$backdrop.addClass('loading');},100)}
else{this.$backdrop.removeClass('loading');}}
else{setTimeout(function(){self.$backdrop.removeClass('loading');},100)}}
Popup.prototype.setShake=function(){var self=this
this.$content.addClass('popup-shaking')
setTimeout(function(){self.$content.removeClass('popup-shaking')},1000)}