Chromium Code Reviews| Index: third_party/WebKit/Source/core/dom/IntersectionObservation.cpp |
| diff --git a/third_party/WebKit/Source/core/dom/IntersectionObservation.cpp b/third_party/WebKit/Source/core/dom/IntersectionObservation.cpp |
| index 724c4312e55bd32fe530d9023a8e2c4d92af009c..051e8b1055ff2b01e45d89f765d8d9da7118dced 100644 |
| --- a/third_party/WebKit/Source/core/dom/IntersectionObservation.cpp |
| +++ b/third_party/WebKit/Source/core/dom/IntersectionObservation.cpp |
| @@ -27,10 +27,8 @@ void IntersectionObservation::computeIntersectionObservations( |
| rootMargin[1] = m_observer->rightMargin(); |
| rootMargin[2] = m_observer->bottomMargin(); |
| rootMargin[3] = m_observer->leftMargin(); |
| - Node* rootNode = m_observer->rootNode(); |
| - IntersectionGeometry geometry( |
| - rootNode && !rootNode->isDocumentNode() ? toElement(rootNode) : nullptr, |
| - *target(), rootMargin, m_shouldReportRootBounds); |
| + IntersectionGeometry geometry(m_observer->root(), *target(), rootMargin, |
| + m_shouldReportRootBounds); |
|
kenrb
2016/12/09 21:01:43
There is something I don't quite understand here.
szager1
2016/12/10 20:51:18
This patch depends on another patch (https://coder
|
| geometry.computeGeometry(); |
| // Some corner cases for threshold index: |