Title: [136852] trunk
- Revision
- 136852
- Author
- [email protected]
- Date
- 2012-12-06 10:02:36 -0800 (Thu, 06 Dec 2012)
Log Message
[chromium] Should apply link highlight to largest enclosing node with a handCursor.
https://bugs.webkit.org/show_bug.cgi?id=104264
Reviewed by Adrienne Walker.
Source/WebKit/chromium:
Link highlights sometimes only apply to part of a link, if we select an enclosed
node (e.g. font changes in link text). The highlight should be applied to the
largest enclosing node that still has handCursor set.
* src/WebViewImpl.cpp:
(WebKit::WebViewImpl::bestTouchLinkNode):
LayoutTests:
Add layout test to cover new functionality.
* platform/chromium-linux/compositing/gestures/gesture-tapHighlight-simple-nested.html: Added.
* platform/chromium-linux/platform/chromium-linux/compositing/gestures/gesture-tapHighlight-simple-nested-expected.png: Added.
* platform/chromium-linux/platform/chromium-linux/compositing/gestures/gesture-tapHighlight-simple-nested-expected.txt: Added.
Modified Paths
Added Paths
Diff
Modified: trunk/LayoutTests/ChangeLog (136851 => 136852)
--- trunk/LayoutTests/ChangeLog 2012-12-06 17:53:26 UTC (rev 136851)
+++ trunk/LayoutTests/ChangeLog 2012-12-06 18:02:36 UTC (rev 136852)
@@ -1,3 +1,16 @@
+2012-12-06 W. James MacLean <[email protected]>
+
+ [chromium] Should apply link highlight to largest enclosing node with a handCursor.
+ https://bugs.webkit.org/show_bug.cgi?id=104264
+
+ Reviewed by Adrienne Walker.
+
+ Add layout test to cover new functionality.
+
+ * platform/chromium-linux/compositing/gestures/gesture-tapHighlight-simple-nested.html: Added.
+ * platform/chromium-linux/platform/chromium-linux/compositing/gestures/gesture-tapHighlight-simple-nested-expected.png: Added.
+ * platform/chromium-linux/platform/chromium-linux/compositing/gestures/gesture-tapHighlight-simple-nested-expected.txt: Added.
+
2012-12-06 Zan Dobersek <[email protected]>
UndoManager layout tests should be removed
Added: trunk/LayoutTests/platform/chromium-linux/compositing/gestures/gesture-tapHighlight-simple-nested.html (0 => 136852)
--- trunk/LayoutTests/platform/chromium-linux/compositing/gestures/gesture-tapHighlight-simple-nested.html (rev 0)
+++ trunk/LayoutTests/platform/chromium-linux/compositing/gestures/gesture-tapHighlight-simple-nested.html 2012-12-06 18:02:36 UTC (rev 136852)
@@ -0,0 +1,33 @@
+<!DOCTYPE html>
+<html>
+<head>
+<script src=""
+</head>
+<body _onload_="runTest();">
+<div style="-webkit-transform: translateZ(0); position: relative; left: 10; top: 40">
+<a href="" id="targetLink" style="-webkit-tap-highlight-color: rgba(0, 255, 0, 0.5)">Target <b id="nestedText">Nested</b> Link.</a>
+</div>
+<div style="position: relative; left: 10; top: 70">
+This test is successful if "Target Nested Link" above is covered in a transparent green rectangle with square corners.
+</div>
+<script>
+function runTest() {
+ var clientRect = document.getElementById('nestedText').getBoundingClientRect();
+ x = (clientRect.left + clientRect.right) / 2;
+ y = (clientRect.top + clientRect.bottom) / 2;
+ if (window.testRunner) {
+ testRunner.dumpAsText(true);
+ testRunner.waitUntilDone();
+ }
+
+ if (window.eventSender) {
+ eventSender.gestureTapDown(x, y);
+ window.setTimeout(function() { window.testRunner.notifyDone(); }, 0);
+ } else {
+ debug("This test requires DumpRenderTree.");
+ }
+}
+</script>
+</script>
+</body>
+</html>
Added: trunk/LayoutTests/platform/chromium-linux/platform/chromium-linux/compositing/gestures/gesture-tapHighlight-simple-nested-expected.png (0 => 136852)
--- trunk/LayoutTests/platform/chromium-linux/platform/chromium-linux/compositing/gestures/gesture-tapHighlight-simple-nested-expected.png (rev 0)
+++ trunk/LayoutTests/platform/chromium-linux/platform/chromium-linux/compositing/gestures/gesture-tapHighlight-simple-nested-expected.png 2012-12-06 18:02:36 UTC (rev 136852)
@@ -0,0 +1,22 @@
+\x89PNG
+
+
+IHDR X ' )tEXtchecksum e4aaf7075e2a4f4bba51a7ebbf09f9bbAO\x90 IDATx\x9C\xED\xDD}\xB4Uu\x9D\xF8\xF1\xA2\xF8\x80"B\xA3\xADP@Ĕ0\xB4\xD0\x98je\xCB\x93\xAEh\xA6\xF9Q3\xB5\x92\xB14\x9BjY)\xD6\xCCZ\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