Title: [163302] trunk
- Revision
- 163302
- Author
- [email protected]
- Date
- 2014-02-03 05:54:32 -0800 (Mon, 03 Feb 2014)
Log Message
[CSS Regions] Fix selection and hover effect of content in region with overflow:hidden
https://bugs.webkit.org/show_bug.cgi?id=127101
Patch by Mihai Maerean <[email protected]> on 2014-02-03
Reviewed by Mihnea Ovidenie.
Source/WebCore:
RenderNamedFlowFragments are not hit candidates. The hit test algorithm will pick the
parent layer, the one of the region.
Test: fast/regions/hover-overflow-hidden.html
* rendering/RenderLayer.cpp:
(WebCore::isHitCandidate):
LayoutTests:
* fast/regions/hover-overflow-hidden.html: Added.
* fast/regions/hover-overflow-hidden-expected.html: Added.
Modified Paths
Added Paths
Diff
Modified: trunk/LayoutTests/ChangeLog (163301 => 163302)
--- trunk/LayoutTests/ChangeLog 2014-02-03 13:43:36 UTC (rev 163301)
+++ trunk/LayoutTests/ChangeLog 2014-02-03 13:54:32 UTC (rev 163302)
@@ -1,3 +1,13 @@
+2014-02-03 Mihai Maerean <[email protected]>
+
+ [CSS Regions] Fix selection and hover effect of content in region with overflow:hidden
+ https://bugs.webkit.org/show_bug.cgi?id=127101
+
+ Reviewed by Mihnea Ovidenie.
+
+ * fast/regions/hover-overflow-hidden.html: Added.
+ * fast/regions/hover-overflow-hidden-expected.html: Added.
+
2014-02-02 Maciej Stachowiak <[email protected]>
Adopt URLUtils interface and template in HTMLAnchorElement and HTMLAreaElement
Added: trunk/LayoutTests/fast/regions/hover-overflow-hidden-expected.html (0 => 163302)
--- trunk/LayoutTests/fast/regions/hover-overflow-hidden-expected.html (rev 0)
+++ trunk/LayoutTests/fast/regions/hover-overflow-hidden-expected.html 2014-02-03 13:54:32 UTC (rev 163302)
@@ -0,0 +1,19 @@
+<!doctype html>
+<html>
+<head>
+ <title>Expected result - Bug 127101: [CSS Regions] Fix selection and hover effect of content in region with overflow:hidden</title>
+ <style>
+ .content {
+ margin: 10px;
+ box-shadow: 0px 0px 0px 10px Green;
+ }
+ body {
+ margin: 0;
+ padding: 0;
+ }
+ </style>
+</head>
+<body>
+ <div class="content">hover me</div>
+</body>
+</html>
\ No newline at end of file
Added: trunk/LayoutTests/fast/regions/hover-overflow-hidden.html (0 => 163302)
--- trunk/LayoutTests/fast/regions/hover-overflow-hidden.html (rev 0)
+++ trunk/LayoutTests/fast/regions/hover-overflow-hidden.html 2014-02-03 13:54:32 UTC (rev 163302)
@@ -0,0 +1,35 @@
+<!doctype html>
+<html>
+<head>
+ <title>Test - Bug 127101: [CSS Regions] Fix selection and hover effect of content in region with overflow:hidden</title>
+ <style>
+ .content {
+ -webkit-flow-into: flow;
+ box-shadow: 0px 0px 0px 10px Red;
+ margin: 10px;
+ }
+ .content:hover {
+ box-shadow: 0px 0px 0px 10px Green;
+ }
+ .region {
+ -webkit-flow-from: flow;
+ overflow: hidden;
+ }
+ body {
+ margin: 0;
+ padding: 0;
+ }
+ </style>
+</head>
+<body>
+ <div class="content">hover me</div>
+ <div class="region">region</div>
+
+ <script type="text/_javascript_">
+ if (window.eventSender) {
+ var box = document.querySelector(".content").getBoundingClientRect();
+ window.eventSender.mouseMoveTo((box.right + box.left) / 2, (box.top + box.bottom) / 2);
+ }
+ </script>
+</body>
+</html>
\ No newline at end of file
Modified: trunk/Source/WebCore/ChangeLog (163301 => 163302)
--- trunk/Source/WebCore/ChangeLog 2014-02-03 13:43:36 UTC (rev 163301)
+++ trunk/Source/WebCore/ChangeLog 2014-02-03 13:54:32 UTC (rev 163302)
@@ -1,3 +1,18 @@
+2014-02-03 Mihai Maerean <[email protected]>
+
+ [CSS Regions] Fix selection and hover effect of content in region with overflow:hidden
+ https://bugs.webkit.org/show_bug.cgi?id=127101
+
+ Reviewed by Mihnea Ovidenie.
+
+ RenderNamedFlowFragments are not hit candidates. The hit test algorithm will pick the
+ parent layer, the one of the region.
+
+ Test: fast/regions/hover-overflow-hidden.html
+
+ * rendering/RenderLayer.cpp:
+ (WebCore::isHitCandidate):
+
2014-02-02 Maciej Stachowiak <[email protected]>
Adopt URLUtils interface and template in HTMLAnchorElement and HTMLAreaElement
Modified: trunk/Source/WebCore/rendering/RenderLayer.cpp (163301 => 163302)
--- trunk/Source/WebCore/rendering/RenderLayer.cpp 2014-02-03 13:43:36 UTC (rev 163301)
+++ trunk/Source/WebCore/rendering/RenderLayer.cpp 2014-02-03 13:54:32 UTC (rev 163302)
@@ -4661,6 +4661,11 @@
{
if (!hitLayer)
return false;
+
+ // RenderNamedFlowFragments are not hit candidates. The hit test algorithm will pick the parent
+ // layer, the one of the region.
+ if (hitLayer->renderer().isRenderNamedFlowFragment())
+ return false;
// The hit layer is depth-sorting with other layers, so just say that it was hit.
if (canDepthSort)
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes