OLD | NEW |
1 // Copyright 2016 The Chromium Authors. All rights reserved. | 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 | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #ifndef DOMWindowWorklet_h | 5 #ifndef WindowPaintWorklet_h |
6 #define DOMWindowWorklet_h | 6 #define WindowPaintWorklet_h |
7 | 7 |
8 #include "core/frame/DOMWindowProperty.h" | 8 #include "core/frame/DOMWindowProperty.h" |
9 #include "platform/Supplementable.h" | 9 #include "platform/Supplementable.h" |
10 #include "platform/heap/Handle.h" | 10 #include "platform/heap/Handle.h" |
11 | 11 |
12 namespace blink { | 12 namespace blink { |
13 | 13 |
14 class DOMWindow; | 14 class DOMWindow; |
15 class ExecutionContext; | 15 class ExecutionContext; |
| 16 class PaintWorklet; |
16 class Worklet; | 17 class Worklet; |
17 | 18 |
18 class DOMWindowWorklet final : public NoBaseWillBeGarbageCollected<DOMWindowWork
let>, public WillBeHeapSupplement<LocalDOMWindow>, public DOMWindowProperty { | 19 class WindowPaintWorklet final : public NoBaseWillBeGarbageCollected<WindowPaint
Worklet>, public WillBeHeapSupplement<LocalDOMWindow>, public DOMWindowProperty
{ |
19 WILL_BE_USING_GARBAGE_COLLECTED_MIXIN(DOMWindowWorklet); | 20 WILL_BE_USING_GARBAGE_COLLECTED_MIXIN(WindowPaintWorklet); |
20 DECLARE_EMPTY_VIRTUAL_DESTRUCTOR_WILL_BE_REMOVED(DOMWindowWorklet); | 21 DECLARE_EMPTY_VIRTUAL_DESTRUCTOR_WILL_BE_REMOVED(WindowPaintWorklet); |
21 USING_FAST_MALLOC_WILL_BE_REMOVED(DOMWindowWorklet); | 22 USING_FAST_MALLOC_WILL_BE_REMOVED(WindowPaintWorklet); |
22 public: | 23 public: |
23 static DOMWindowWorklet& from(LocalDOMWindow&); | 24 static WindowPaintWorklet& from(LocalDOMWindow&); |
24 static Worklet* renderWorklet(ExecutionContext*, DOMWindow&); | 25 static Worklet* paintWorklet(ExecutionContext*, DOMWindow&); |
25 Worklet* renderWorklet(ExecutionContext*) const; | 26 PaintWorklet* paintWorklet(ExecutionContext*) const; |
26 | 27 |
27 DECLARE_TRACE(); | 28 DECLARE_TRACE(); |
28 | 29 |
29 private: | 30 private: |
30 explicit DOMWindowWorklet(LocalDOMWindow&); | 31 explicit WindowPaintWorklet(LocalDOMWindow&); |
31 static const char* supplementName(); | 32 static const char* supplementName(); |
32 | 33 |
33 mutable PersistentWillBeMember<Worklet> m_renderWorklet; | 34 mutable PersistentWillBeMember<PaintWorklet> m_paintWorklet; |
34 }; | 35 }; |
35 | 36 |
36 } // namespace blink | 37 } // namespace blink |
37 | 38 |
38 #endif // DOMWindowWorklet_h | 39 #endif // WindowPaintWorklet_h |
OLD | NEW |