[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-bugs-dist
Subject:    Bug#20290: no crash in KDE 2.2, but Mouse Event handler (DOM, KJS) doesn't work, testcase included
From:       David Faure <david () mandrakesoft ! com>
Date:       2001-10-31 15:09:21
[Download RAW message or body]

On Mercredi 31 Octobre 2001 18:12, Vadim Plessky wrote:
> alert ("OrigWidth = "+OrigWidth+" OrigHeight= "+ OrigHeight+"\n 
> WindowLeftEdge= "+WindowLeftEdge+" WindowTopEdge= "+WindowTopEdge); 

This statement has a string constant going over two lines, which leads to a parse \
error.

Ah, maybe this is just a copy-n-paste problem... please attach testfiles next time ;)

Ok, after fixing several of such newline problems.....
.. adding debug output....

--> (1)s=<BR>clientX= 298, clientY = 135<BR> x_Offset= undefined, y_Offset = \
undefined<BR>screenX= 304, screenY = 321<BR>e.button= 0<BR>  e.type= mouseover<BR> \
                e.x= 298 e.y= 135<BR>document.body.scrollLeft = -10 .scrollTop= -10
--> ClickElement=undefined

There. This bug is in fact
"event.srcElement" isn't implemented.

If you replace 
var ClickElement = /*(IE) ? e.srcElement :*/ e.target;
with
var ClickElement = e.target;
in the testcase, it starts working.

I'll have to lookup the definition of srcElement (yet another IE extension I guess!),
no time right now.

David.


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic