Ahem,
I have figured outsomething for IE and Netscape.
It's not a particularly nice solution (because it represents a large
computational overhead for the browser), but so far on my
smaller test cases it seems to be working on still mouse down
events (without mouse movement).
Replace the onmousedown line as follows:
onmousedown="this.style.cursor='move';window.resiz eBy(1,0);window.resizeBy(-1,0)"
Sadly, it has not made a difference for Opera.
In Netscape 6+, the overhead of the two window.resizeBy calls may be bypassed
by using, instead, window.setCursor('move')
Csaba
"Csaba2000" <news@CsabaGabor.com> wrote in message news:bjqii8$oi5@dispatch.concentric.net...[color=blue]
> I have set onmousedown to change the cursor, but this setting is ignored
> (IE 5.5; NN 6.1 on Win 2K Pro) until the mouse is either moved or the
> mouse button is released. On Opera 7.01, the setting seems to be ignored
> completely, even when I try with window.setTimeout.
>
> So my two questions are: (1) Most important: Is there anything I can do
> so that I don't have to wait for the next mouse event before the cursor
> gets repainted. (2) Why is this not working for Opera at all?
>
> The page below can also be found at
http://csaba.org/demos/revert.htm
>
> Things I have tried include window.setTimeout for the cursor change,
> putting in a <STYLE> section and trying to change the cursor by means
> of changing the class, faking a mouse event by putting in a fireEvent to
> simulate a mouseMove. Same behaviour as above for all attempts.
>
> This problem also happens on the other side. That is, in a situation
> where I have changed the mouse cursor on the down click (subsequently
> to moving the mouse) and then I want to revert it on a onmouseup, I
> should move the mouse before the cursor changes. That's not nice.
>
> Thanks for any tips,
> Csaba Gabor from New York
>
>
> <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
> <HTML>
> <HEAD>
> <META http-equiv="content-type" content="text/html;charset=iso-8859-1">
> <TITLE>Cursor changing demo</TITLE>
> </HEAD>
> <BODY bgcolor=gold style="margin-left:5%;margin-top:10%">
> <DIV style="border:blue 1px solid"
> onmouseout="this.style.cursor='auto'"
> onmouseover="this.style.cursor='se-resize'"
> onmousedown="this.style.cursor='move'">Click and drag</DIV>
> <BR><BR><BR>
> If you move the mouse over the DIV then its type should change to 'se-resize'.
> <BR><BR>
> If you now click (and hold) without moving the mouse,
> the cursor should change to a 'move' type.
> In Opera 7.01 the cursor type does not change at all.
>
> In both IE 5.5 and Netscape 6.1 I either have to release
> the mouse button, or move it (with the button still
> clicked) in order to get the cursor to change. This does
> not seem reasonable.
> </BODY>
> </HTML>
>
>
>[/color]