Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(301)

Unified Diff: third_party/WebKit/Source/core/dom/IntersectionObserverEntry.cpp

Issue 1615573002: Set rootBounds to null for cross-origin observations. (Closed) Base URL: https://chromium.googlesource.com/chromium/src@master
Patch Set: Get rid of js-test.js monkey patching Created 4 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/Source/core/dom/IntersectionObserverEntry.cpp
diff --git a/third_party/WebKit/Source/core/dom/IntersectionObserverEntry.cpp b/third_party/WebKit/Source/core/dom/IntersectionObserverEntry.cpp
index 1511a2a4692f30115cb919e2926ffec36c2b95c1..a3d358b03ec9196530d3394f1c6c944ee88d0884 100644
--- a/third_party/WebKit/Source/core/dom/IntersectionObserverEntry.cpp
+++ b/third_party/WebKit/Source/core/dom/IntersectionObserverEntry.cpp
@@ -8,10 +8,10 @@
namespace blink {
-IntersectionObserverEntry::IntersectionObserverEntry(double time, const IntRect& boundingClientRect, const IntRect& rootBounds, const IntRect& intersectionRect, Element* target)
+IntersectionObserverEntry::IntersectionObserverEntry(double time, const IntRect& boundingClientRect, const IntRect* rootBounds, const IntRect& intersectionRect, Element* target)
: m_time(time)
, m_boundingClientRect(ClientRect::create(boundingClientRect))
- , m_rootBounds(ClientRect::create(rootBounds))
+ , m_rootBounds(rootBounds ? ClientRect::create(*rootBounds) : nullptr)
, m_intersectionRect(ClientRect::create(intersectionRect))
, m_target(target)

Powered by Google App Engine
This is Rietveld 408576698