Mercurial > public > sg101
diff gpp/shoutbox/static/js/shoutbox.js @ 427:85d7b62d5c17
Added a global method to change the cursor to an hourglass when an AJAX request fires.
author | Brian Neal <bgneal@gmail.com> |
---|---|
date | Tue, 26 Apr 2011 02:11:00 +0000 |
parents | c3d3d7114749 |
children |
line wrap: on
line diff
--- a/gpp/shoutbox/static/js/shoutbox.js Tue Apr 26 01:04:38 2011 +0000 +++ b/gpp/shoutbox/static/js/shoutbox.js Tue Apr 26 02:11:00 2011 +0000 @@ -23,6 +23,12 @@ } }); + $("html").bind("ajaxStart", function() { + $(this).addClass('busy'); + }).bind("ajaxStop", function() { + $(this).removeClass('busy'); + }); + var numShouts = $('#shoutbox-shout-container > p').size(); var sbBox = $('#shoutbox-shout-container');