[webkit-dev] Question related with HitTest.

KwangHyuk Kim hyuki.kim at samsung.com
Sat Dec 3 02:12:25 PST 2011


Hi, all,

I would like to get some idea related with HitTest.

I tested simple test page by use safari and chrome browser and you can find test page from https://bugs.webkit.org/show_bug.cgi?id=73738.
- chrome : Ver 15.0.874.121 m (window machine)
- safari : Ver 5.1.2 (window machine)

From the test page, WebCore doesn't seem to provide expected HitTestResult for the region which overlapping with both text label ("Put Your Password") and input field.
It seem to detect only label when mouse is on that region.
So, browser doesn't provide context popup includes paste item which editable field can support.

According to my initial investigation, WebCore seems to stop doing HitTest as soon as it meets label since label is positioned on the separate RenderLayer because of "position:absolute" property.
As a result, It doesn't seem to do HitTest for input field no longer.

I would like to know whether this is a normal Webkit's policy for the HitTest.
If it will be an intended operation, I would like to know the reason why Webkit doesn't allow HitTest via all RenderLayers.
Should browser application check whether current focused node is editable in addition to WebCore's HitTest ?

I am sincerely hoping to get any good idea for this. :)

Best Regards
 - Kwang


More information about the webkit-dev mailing list