Bug 15073 - REGRESSION: Often can't drag text out of textareas.
Summary: REGRESSION: Often can't drag text out of textareas.
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Forms (show other bugs)
Version: 523.x (Safari 3)
Hardware: Mac OS X 10.4
: P1 Normal
Assignee: Nobody
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2007-08-24 13:36 PDT by Adele Peterson
Modified: 2007-08-25 09:41 PDT (History)
1 user (show)

See Also:


Attachments
testcase (42 bytes, text/html)
2007-08-24 13:37 PDT, Adele Peterson
no flags Details
patch (1.96 KB, patch)
2007-08-24 19:36 PDT, Adele Peterson
mitz: review+
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Adele Peterson 2007-08-24 13:36:35 PDT
In the attached test case, select the word "test" and try to drag it out of the textarea and into the text field.  

I think this is caused by the change in hit testing for text controls.  Now we get the inner div as the hit test result, and when EventHandler::shouldDragAutoNode gets called (eventually on the textarea itself), it fails because the textarea isn't a leaf node.

<rdar://problem/5426557>
Comment 1 Adele Peterson 2007-08-24 13:37:55 PDT
Created attachment 16109 [details]
testcase
Comment 2 mitz 2007-08-24 17:06:50 PDT
(In reply to comment #0)
> I think this is caused by the change in hit testing for text controls.  Now we
> get the inner div as the hit test result, and when
> EventHandler::shouldDragAutoNode gets called (eventually on the textarea
> itself), it fails because the textarea isn't a leaf node.

I agree. I think the special hit-testing should be reserved to text controls while they're actually displaying placeholder text. I am going to make that patch.
Comment 3 Adele Peterson 2007-08-24 19:36:26 PDT
Created attachment 16114 [details]
patch

I took a stab at this...

Still needs a layout test though.  Passes existing tests.
Comment 4 mitz 2007-08-24 23:30:13 PDT
Comment on attachment 16114 [details]
patch

r=me assuming you add a test
Comment 5 Adele Peterson 2007-08-25 09:41:19 PDT
Committed revision 25245.