| Index: third_party/WebKit/Source/core/dom/IntersectionObserver.cpp
|
| diff --git a/third_party/WebKit/Source/core/dom/IntersectionObserver.cpp b/third_party/WebKit/Source/core/dom/IntersectionObserver.cpp
|
| index 1970c981dc1e8de5d0fe50185daa80c0d5569d65..7da91ebc19173844a08fff4ebb5a47bbdc1fa91e 100644
|
| --- a/third_party/WebKit/Source/core/dom/IntersectionObserver.cpp
|
| +++ b/third_party/WebKit/Source/core/dom/IntersectionObserver.cpp
|
| @@ -102,12 +102,12 @@ void parseRootMargin(String rootMarginParameter, Vector<Length>& rootMargin, Exc
|
| }
|
| }
|
|
|
| -void parseThresholds(const DoubleOrDoubleArray& thresholdParameter, Vector<float>& thresholds, ExceptionState& exceptionState)
|
| +void parseThresholds(const DoubleOrDoubleSequence& thresholdParameter, Vector<float>& thresholds, ExceptionState& exceptionState)
|
| {
|
| if (thresholdParameter.isDouble()) {
|
| thresholds.append(static_cast<float>(thresholdParameter.getAsDouble()));
|
| } else {
|
| - for (auto thresholdValue : thresholdParameter.getAsDoubleArray())
|
| + for (auto thresholdValue : thresholdParameter.getAsDoubleSequence())
|
| thresholds.append(static_cast<float>(thresholdValue));
|
| }
|
|
|
| @@ -148,16 +148,12 @@ IntersectionObserver* IntersectionObserver::create(const IntersectionObserverIni
|
| }
|
|
|
| Vector<Length> rootMargin;
|
| - if (observerInit.hasRootMargin())
|
| - parseRootMargin(observerInit.rootMargin(), rootMargin, exceptionState);
|
| + parseRootMargin(observerInit.rootMargin(), rootMargin, exceptionState);
|
| if (exceptionState.hadException())
|
| return nullptr;
|
|
|
| Vector<float> thresholds;
|
| - if (observerInit.hasThreshold())
|
| - parseThresholds(observerInit.threshold(), thresholds, exceptionState);
|
| - else
|
| - thresholds.append(0);
|
| + parseThresholds(observerInit.threshold(), thresholds, exceptionState);
|
| if (exceptionState.hadException())
|
| return nullptr;
|
|
|
|
|