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

Side by Side Diff: third_party/WebKit/Source/bindings/core/v8/V8IntersectionObserverCallback.h

Issue 1449623002: IntersectionObserver: second cut. (Closed) Base URL: https://chromium.googlesource.com/chromium/src@master
Patch Set: Add RuntimeEnabled flags to all idl's, fix test expectations. 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 unified diff | Download patch
OLDNEW
(Empty)
1 // Copyright 2016 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #ifndef V8IntersectionObserverCallback_h
6 #define V8IntersectionObserverCallback_h
7
8 #include "bindings/core/v8/ActiveDOMCallback.h"
9 #include "bindings/core/v8/DOMWrapperWorld.h"
10 #include "bindings/core/v8/ScopedPersistent.h"
11 #include "core/CoreExport.h"
12 #include "core/dom/IntersectionObserverCallback.h"
13
14 namespace blink {
15
16 class V8IntersectionObserverCallback final : public IntersectionObserverCallback , public ActiveDOMCallback {
17 WILL_BE_USING_GARBAGE_COLLECTED_MIXIN(V8IntersectionObserverCallback);
18 public:
19 CORE_EXPORT V8IntersectionObserverCallback(v8::Local<v8::Function>, v8::Loca l<v8::Object>, ScriptState*);
20 ~V8IntersectionObserverCallback() override;
21
22 DECLARE_VIRTUAL_TRACE();
23
24 void handleEvent(const HeapVector<Member<IntersectionObserverEntry>>&, Inter sectionObserver&) override;
25 ExecutionContext* executionContext() const override { return ContextLifecycl eObserver::executionContext(); }
26 private:
27
28 static void setWeakCallback(const v8::WeakCallbackInfo<V8IntersectionObserve rCallback>&);
29
30 ScopedPersistent<v8::Function> m_callback;
31 RefPtr<ScriptState> m_scriptState;
32 };
33
34 }
35 #endif // V8IntersectionObserverCallback_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698