# HG changeset patch # User Brian Neal # Date 1303783860 0 # Node ID 85d7b62d5c17433508df9cbda75878604c99f553 # Parent c8148cf11a79ef0f2d473e3f8156e630e9ff594d Added a global method to change the cursor to an hourglass when an AJAX request fires. diff -r c8148cf11a79 -r 85d7b62d5c17 gpp/shoutbox/static/js/shoutbox.js --- 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'); diff -r c8148cf11a79 -r 85d7b62d5c17 static/css/base.css --- a/static/css/base.css Tue Apr 26 01:04:38 2011 +0000 +++ b/static/css/base.css Tue Apr 26 02:11:00 2011 +0000 @@ -443,3 +443,6 @@ .middle { vertical-align: middle; } +html.busy, html.busy * { + cursor: wait !important; +}