Bug 24317 - hitTest() on a multi line input only works through happenstance.
Summary: hitTest() on a multi line input only works through happenstance.
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Forms (show other bugs)
Version: 528+ (Nightly build)
Hardware: Mac OS X 10.5
: P2 Normal
Assignee: Simon Fraser (smfr)
URL:
Keywords:
Depends on:
Blocks: 24312
  Show dependency treegraph
 
Reported: 2009-03-02 22:43 PST by Simon Fraser (smfr)
Modified: 2009-03-03 09:43 PST (History)
2 users (show)

See Also:


Attachments
Patch (1.49 KB, patch)
2009-03-02 23:05 PST, Simon Fraser (smfr)
hyatt: review+
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Simon Fraser (smfr) 2009-03-02 22:43:13 PST
Another, just like bug 24313:
Hit testing on a RenderTextControlMultiLine seems to work only because of a side-effect of HitTestResult behavior.

What I see happening is this:
RenderLayer::hitTest calls hitTest() on the renderer, which goes into RenderTextControlMultiLine::nodeAtPoint(). This ends up setting some text node inside the textarea as the innerNode() on the result. However, RenderTextControlMultiLine::nodeAtPoint() then returns false!

So we continue to hit test all the way up to the body. The body's layer ends up being the one hit, but we use the node in the result anyway.

This is hurting my karma. See bug 24312.
Comment 1 Simon Fraser (smfr) 2009-03-02 23:05:00 PST
Created attachment 28213 [details]
Patch
Comment 2 Dave Hyatt 2009-03-03 09:05:59 PST
Comment on attachment 28213 [details]
Patch

r=me
Comment 3 Simon Fraser (smfr) 2009-03-03 09:43:57 PST
http://trac.webkit.org/changeset/41385