| Index: third_party/WebKit/Source/core/layout/LayoutBox.cpp
|
| diff --git a/third_party/WebKit/Source/core/layout/LayoutBox.cpp b/third_party/WebKit/Source/core/layout/LayoutBox.cpp
|
| index f8eec36954260aa67f8b21b2f906b1a6295df3f7..5c3b3afe4736616028e2b3511b10810084656d4f 100644
|
| --- a/third_party/WebKit/Source/core/layout/LayoutBox.cpp
|
| +++ b/third_party/WebKit/Source/core/layout/LayoutBox.cpp
|
| @@ -1399,7 +1399,7 @@ bool LayoutBox::nodeAtPoint(HitTestResult& result,
|
| // TODO(pdr): We should also check for css clip in the !isSelfPaintingLayer
|
| // case, similar to overflow clip below.
|
| bool skipChildren = false;
|
| - if (hasOverflowClip() && !hasSelfPaintingLayer()) {
|
| + if (shouldClipOverflow() && !hasSelfPaintingLayer()) {
|
| if (!locationInContainer.intersects(overflowClipRect(
|
| adjustedLocation, ExcludeOverlayScrollbarSizeForHitTesting))) {
|
| skipChildren = true;
|
| @@ -1410,11 +1410,6 @@ bool LayoutBox::nodeAtPoint(HitTestResult& result,
|
| }
|
| }
|
|
|
| - // A control clip can also clip out child hit testing.
|
| - if (!skipChildren && hasControlClip() &&
|
| - !locationInContainer.intersects(controlClipRect(adjustedLocation)))
|
| - skipChildren = true;
|
| -
|
| // TODO(pdr): We should also include checks for hit testing border radius at
|
| // the layer level (see: crbug.com/568904).
|
|
|
| @@ -1799,6 +1794,10 @@ LayoutRect LayoutBox::overflowClipRect(
|
|
|
| if (hasOverflowClip())
|
| excludeScrollbars(clipRect, overlayScrollbarClipBehavior);
|
| +
|
| + if (hasControlClip())
|
| + clipRect.intersect(controlClipRect(location));
|
| +
|
| return clipRect;
|
| }
|
|
|
|
|