Bug 11718 - REGRESSION: When I mouse up after dragging a selection outside of a iframe, the iframe continues to scroll automatically.
Summary: REGRESSION: When I mouse up after dragging a selection outside of a iframe, t...
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Frames (show other bugs)
Version: 420+
Hardware: Mac OS X 10.4
: P1 Major
Assignee: Alexey Proskuryakov
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2006-11-29 11:20 PST by Chris Petersen
Modified: 2006-12-08 10:44 PST (History)
0 users

See Also:


Attachments
iFrame test case (141 bytes, text/html)
2006-11-29 11:23 PST, Chris Petersen
no flags Details
proposed fix (4.47 KB, patch)
2006-12-02 12:16 PST, Alexey Proskuryakov
ggaren: review+
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Chris Petersen 2006-11-29 11:20:27 PST
11/29/06 8:30 AM Chris Petersen:
* SUMMARY
After I mouse up after dragging a selection outside of the iframe, the iframe continues to scroll. This is the wrong behavior since scrolling should stop in iframe after I mouse up (outside of the iframe).

This regression first started with Webkit Nightly r17582 since this works with the previous nightly r17566. 

* STEPS TO REPRODUCE
1. With webkit nightly r17582 or newer, open test case "iframe_test.html"
2. Place in focus in the iframe and mouse down. Start to drag a selection over text in the iframe and continue to mouse down. Move the cursor so that it just outside the bottom of iframe. This should cause the iframe to scroll.
3. Now, mouse up while the iframe is scrolling. Notice the iframe DOESN'T stop scrolling when you mouse up.

* RESULTS
iFrame scrolling should stop when mousing up outside of iframe but doesn't.

* REGRESSION
Yes, this doesn't happen in stock Safari under Tiger.
Comment 1 Chris Petersen 2006-11-29 11:20:49 PST
I believe this is the likely candidate that caused this regression:

http://trac.webkit.org/projects/webkit/changeset/17574
Comment 2 Chris Petersen 2006-11-29 11:22:06 PST
This is filed as <rdar://problem/4854259>
Comment 3 Chris Petersen 2006-11-29 11:23:17 PST
Created attachment 11670 [details]
iFrame test case
Comment 4 Alexey Proskuryakov 2006-12-02 12:16:30 PST
Created attachment 11714 [details]
proposed fix

This fix makes an EventHandler hold a reference to a subframe's node in m_mousePressNode - previously, this data member wasn't reset for subframe events, continuing to reference nodes from earlier actions.

There seems to be a lot of duplication in EventHandler data members at the moment (m_mousePressNode vs. m_clickNode; m_bMousePressed vs. m_mousePressed). I chose not to attempt merging any of these in this patch, and plan to file a follow-up bug.
Comment 5 Geoffrey Garen 2006-12-07 15:17:57 PST
Comment on attachment 11714 [details]
proposed fix

r=me

Please do file that follow-up bug.
Comment 6 Alexey Proskuryakov 2006-12-08 10:44:16 PST
Committed revision 18079. Filed follow-up bug 11784.