| Index: third_party/WebKit/Source/core/dom/IntersectionObserverController.h
|
| diff --git a/third_party/WebKit/Source/core/dom/IntersectionObserverController.h b/third_party/WebKit/Source/core/dom/IntersectionObserverController.h
|
| index fe4bb867083354e71b07927c6b454e5d54830c2c..efc3d6571a6a53af3cc026440e1c7bc8c4013bb2 100644
|
| --- a/third_party/WebKit/Source/core/dom/IntersectionObserverController.h
|
| +++ b/third_party/WebKit/Source/core/dom/IntersectionObserverController.h
|
| @@ -11,13 +11,18 @@
|
| #include "platform/heap/Handle.h"
|
| #include "wtf/HashSet.h"
|
|
|
| +// Design doc for IntersectionObserver implementation:
|
| +// https://docs.google.com/a/google.com/document/d/1hLK0eyT5_BzyNS4OkjsnoqqFQDYCbKfyBinj94OnLiQ
|
| +
|
| namespace blink {
|
|
|
| -class IntersectionObserverController : public GarbageCollectedFinalized<IntersectionObserverController> {
|
| +class IntersectionObserverController : public GarbageCollectedFinalized<IntersectionObserverController>, public ActiveDOMObject {
|
| public:
|
| - IntersectionObserverController();
|
| + static IntersectionObserverController* create(Document*);
|
| ~IntersectionObserverController();
|
|
|
| + void resume() override;
|
| +
|
| void scheduleIntersectionObserverForDelivery(IntersectionObserver&);
|
| void deliverIntersectionObservations(Timer<IntersectionObserverController>*);
|
| void computeTrackedIntersectionObservations();
|
| @@ -27,14 +32,16 @@ public:
|
| DECLARE_TRACE();
|
|
|
| private:
|
| - // Design doc for IntersectionObserver implementation:
|
| - // https://docs.google.com/a/google.com/document/d/1hLK0eyT5_BzyNS4OkjsnoqqFQDYCbKfyBinj94OnLiQ
|
| + explicit IntersectionObserverController(Document*);
|
|
|
| +private:
|
| Timer<IntersectionObserverController> m_timer;
|
| // IntersectionObservers for which this is the tracking document.
|
| HeapHashSet<WeakMember<IntersectionObserver>> m_trackedIntersectionObservers;
|
| // IntersectionObservers for which this is the execution context of the callback.
|
| HeapHashSet<Member<IntersectionObserver>> m_pendingIntersectionObservers;
|
| +
|
| + bool m_timerFiredWhileSuspended;
|
| };
|
|
|
| } // namespace blink
|
|
|