Change cursor to wait when running a lengthy JQuery operation
<p>I am having a trouble display the cursor wait when I run a lengthy jQuery operation. What I try is</p>

<pre><code>function foo(){
   jQuery('body').css('cursor', 'wait');

   //lengthy jQuery sort/DOM manipulation

   jQuery('body').css('cursor', 'default');
}
</code></pre>

<p>what I have observe so far is that, it looks to me like when <code>onclick</code>, invoke this function, it take about 6 seconds (time it takes to operate the sort), then I see all the changes at the end. This make sense since I am still within the same JQuery call, but is there a way to force the cursor change to show to wait, then after the sort operation, and change the cursor back to default once it is done.</p>

<p>NOTE: The length operation is not an ajax call.</p>
