News for hackers. Stuff that matters.
Re:Forget tacky loading spinners, just use a wait cursor by enapupe on Monday February 20, 2012 @04:02PM (#3613913)
Did this (using jquery):

var loadingLayer = { step: 0, add: function(){ this.step += 1; //didn't know how to call checkState() automatically after any other call this.checkState(); }, remove: function(){ this.step -= 1; this.step < 0 && (this.step=0); this.checkState(); }, clear: function(){ this.step = 0; this.checkState(); }, checkState: function(){ if (this.step === 0){ $("body").removeClass("loading"); } else { $("body").addClass("loading"); } } }; $(document).ajaxStart( function(){ loadingLayer.add(); }); $(document).ajaxComplete(function(){ loadingLayer.remove(); });

I know the JS is uggly but i'm not an js expert (it works).

Re:Forget tacky loading spinners, just use a wait cursor by enapupe on Monday February 20, 2012 @04:12PM (#3613957)