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 836c7e887028a725525e433a47fcb509e6a220ec..0322d90aa90340cdea7e32d471c688e387d5095d 100644 |
--- a/third_party/WebKit/Source/core/layout/LayoutBox.cpp |
+++ b/third_party/WebKit/Source/core/layout/LayoutBox.cpp |
@@ -572,6 +572,8 @@ void LayoutBox::scrollRectToVisible(const LayoutRect& rect, const ScrollAlignmen |
// Don't scroll to reveal an overflow layer that is restricted by the -webkit-line-clamp property. |
// This will prevent us from revealing text hidden by the slider in Safari RSS. |
newRect = getScrollableArea()->scrollIntoView(rect, alignX, alignY, scrollType); |
+ if (newRect == LayoutRect()) |
bokan
2016/08/26 16:12:14
use newRect.isEmpty() instead
|
+ return; |
} else if (!parentBox && canBeProgramaticallyScrolled()) { |
if (FrameView* frameView = this->frameView()) { |
HTMLFrameOwnerElement* ownerElement = document().localOwner(); |