views:

37

answers:

3

I would like the user's cursor to be in "wait-state" during certain actions, but the problems with using the CSS cursor property is forcing me to search for more... creative solutions. (The problem I'm referring to, is that the cursor doesn't change until the user moves the cursor. See, for example: http://stackoverflow.com/questions/1752372/how-to-get-cursor-to-change-before-mouse-moves-when-changing-the-cursor-style-dyn.)

I've found however, that most browsers seem to correctly switch back and forth through wait and default cursor when making AJAX requests. So now I was thinking do a dummy AJAX requests for as long as I want the cursor to be in "wait". I feel that this might be a Very Bad Idea, but I can't really point out why. Any good reasons why this is bad? (Or much better solutions?)

A: 

its a bad idea because it increases load and traffic on the server.

Christian Smorra
A: 

Yes, it is a bad idea. A waiting cursor may make the user think his browser (or connection) is frozen.

Web pages give you plenty of options for waiting feedback: progress bars, spinners, feedback text, modal feedback windows, disabling commands... use one (or more) of those instead.

Agos
A: 

I found a possible solution myself. (This is more for future users who come across this problem, really, since I've since come to agree that using the cursor for feedback is A Bad Idea in general.)
I found that if the first change of the cursor is in an eventhandler of a mouse-event (like "click", or "move"), not only will the cursor change immediately, it will also change immediately again if changed at a later time with setTimeout or setInterval, given that setInterval or setTimeout were also called within that eventhandler.
Yes, weird.

Protector one