- fix http://bugzilla.opendarwin.org/show_bug.cgi?id=5923
REGRESSION: scrolling on Google maps continues after the mouse is
released outside the window
Test: fast/events/drag-outside-window.html
* rendering/render_layer.cpp:
(WebCore::RenderLayer::containsPoint): Always return true for the root
object to ensure that mouse events occurring outside the window target
the document.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@13265
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
+2006-03-12 Mitz Pettel <opendarwin.org@mitzpettel.com>
+
+ Reviewed by Maciej, landed by ap.
+
+ - test for http://bugzilla.opendarwin.org/show_bug.cgi?id=5923
+ REGRESSION: scrolling on Google maps continues after the mouse is
+ released outside the window
+
+ * fast/events/drag-outside-window-expected.txt: Added.
+ * fast/events/drag-outside-window.html: Added.
+ * fast/events/resources: Added.
+ * fast/events/resources/drag-outside-window-frame.html: Added.
+
2006-03-12 Alexey Proskuryakov <ap@nypop.com>
Reviewed by Maciej.
--- /dev/null
+EDITING DELEGATE: shouldChangeSelectedDOMRange:(null) toDOMRange:range from 31 of #text > P > BODY > HTML > #document to 31 of #text > P > BODY > HTML > #document affinity:NSSelectionAffinityDownstream stillSelecting:FALSE
+EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
+EDITING DELEGATE: shouldChangeSelectedDOMRange:range from 31 of #text > P > BODY > HTML > #document to 31 of #text > P > BODY > HTML > #document toDOMRange:range from 31 of #text > P > BODY > HTML > #document to 31 of #text > P > BODY > HTML > #document affinity:NSSelectionAffinityDownstream stillSelecting:FALSE
+ALERT: Test result: PASS
+
--- /dev/null
+<frameset cols="100, *">
+<frame>
+<frame src="resources/drag-outside-window-frame.html">
+</frameset>
--- /dev/null
+<body onload="test()">
+<script type="text/javascript">
+document.addEventListener("mousemove", mousemoved);
+
+var result = "FAIL";
+
+function mousemoved(event)
+{
+ if (event.clientX < -1)
+ result = "PASS";
+}
+
+function test()
+{
+ if (!window.layoutTestController)
+ return;
+ layoutTestController.dumpAsText();
+ eventSender.mouseMoveTo(150, 100);
+ eventSender.mouseDown();
+ eventSender.mouseMoveTo(50, 100);
+ alert("Test result: " + result);
+}
+</script>
+<p>
+ This is a test for <i><a href="http://bugzilla.opendarwin.org/show_bug.cgi?id=5923">http://bugzilla.opendarwin.org/show_bug.cgi?id=5923</a>
+ REGRESSION: scrolling on Google maps continues after the mouse is released outside the window</i>.
+</p>
+<p>
+ (Cannot run interactively)
+</p>
+</body>
-2006-03-13 Alexey Proskuryakov <ap@nypop.com>
+2006-03-12 Mitz Pettel <opendarwin.org@mitzpettel.com>
+
+ Reviewed by Maciej, landed by ap.
+
+ - fix http://bugzilla.opendarwin.org/show_bug.cgi?id=5923
+ REGRESSION: scrolling on Google maps continues after the mouse is
+ released outside the window
+
+ Test: fast/events/drag-outside-window.html
+
+ * rendering/render_layer.cpp:
+ (WebCore::RenderLayer::containsPoint): Always return true for the root
+ object to ensure that mouse events occurring outside the window target
+ the document.
+
+2006-03-12 Alexey Proskuryakov <ap@nypop.com>
Reviewed by Maciej.
bool RenderLayer::containsPoint(int x, int y, const IntRect& damageRect) const
{
- return damageRect.contains(x, y);
+ // Always returning true for the root object to ensure that mouse events occurring
+ // outside the window (when dragging) always target some node.
+ return renderer()->isRoot() || damageRect.contains(x, y);
}
void RenderLayer::clearClipRects()