[Webkit-unassigned] [Bug 24570] New: After the webview is scrolled then the document.elementFromPoint return the incorrect element.

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Fri Mar 13 04:00:00 PDT 2009


https://bugs.webkit.org/show_bug.cgi?id=24570

           Summary: After the webview is scrolled then the
                    document.elementFromPoint return the incorrect element.
           Product: WebKit
           Version: 528+ (Nightly build)
          Platform: PC
        OS/Version: Windows XP
            Status: UNCONFIRMED
          Severity: Normal
          Priority: P2
         Component: HTML DOM
        AssignedTo: webkit-unassigned at lists.webkit.org
        ReportedBy: weihong.zeng at hotmail.com


<script>
function handleMouseMove(event)
{
        var srcEvent = event;
        var ele = document.elementFromPoint(srcEvent.clientX,
srcEvent.clientY);
        document.getElementById("content").innerHTML = "Move by client(" +
srcEvent.clientX + ","+ srcEvent.clientY + ")" + ele.tagName + "<br>";
}
</script>

<body onmousemove="handleMouseMove(event);">
<img src="." height=1000px width=1000px>

<div id="content">
</div>
<a href="http://www.webkit.org">webkit</a><br>
<img src="." height=200px width=100px>
</body>

When the mouse pointer moves to the anchor "webkit", the result of the
document.write is "Move by client(43,725)IMG". 
but "Move by client(43,725)A" is writed in Firefox and IE.

I think it's more reasonable that document.elementFromPoint converts clientX
and clintY according to the scroll bar position coordinates.


-- 
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.



More information about the webkit-unassigned mailing list