| 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 WindowPaintWorklet_h | 5 #ifndef WindowPaintWorklet_h |
| 6 #define WindowPaintWorklet_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 PaintWorklet; |
| 17 class Worklet; | 17 class Worklet; |
| 18 | 18 |
| 19 class WindowPaintWorklet final : public NoBaseWillBeGarbageCollected<WindowPaint
Worklet>, public WillBeHeapSupplement<LocalDOMWindow>, public DOMWindowProperty
{ | 19 class WindowPaintWorklet final : public GarbageCollected<WindowPaintWorklet>, pu
blic HeapSupplement<LocalDOMWindow>, public DOMWindowProperty { |
| 20 WILL_BE_USING_GARBAGE_COLLECTED_MIXIN(WindowPaintWorklet); | 20 USING_GARBAGE_COLLECTED_MIXIN(WindowPaintWorklet); |
| 21 DECLARE_EMPTY_VIRTUAL_DESTRUCTOR_WILL_BE_REMOVED(WindowPaintWorklet); | |
| 22 USING_FAST_MALLOC_WILL_BE_REMOVED(WindowPaintWorklet); | |
| 23 public: | 21 public: |
| 24 static WindowPaintWorklet& from(LocalDOMWindow&); | 22 static WindowPaintWorklet& from(LocalDOMWindow&); |
| 25 static Worklet* paintWorklet(ExecutionContext*, DOMWindow&); | 23 static Worklet* paintWorklet(ExecutionContext*, DOMWindow&); |
| 26 PaintWorklet* paintWorklet(ExecutionContext*) const; | 24 PaintWorklet* paintWorklet(ExecutionContext*) const; |
| 27 | 25 |
| 28 DECLARE_TRACE(); | 26 DECLARE_TRACE(); |
| 29 | 27 |
| 30 private: | 28 private: |
| 31 explicit WindowPaintWorklet(LocalDOMWindow&); | 29 explicit WindowPaintWorklet(LocalDOMWindow&); |
| 32 static const char* supplementName(); | 30 static const char* supplementName(); |
| 33 | 31 |
| 34 mutable PersistentWillBeMember<PaintWorklet> m_paintWorklet; | 32 mutable Member<PaintWorklet> m_paintWorklet; |
| 35 }; | 33 }; |
| 36 | 34 |
| 37 } // namespace blink | 35 } // namespace blink |
| 38 | 36 |
| 39 #endif // WindowPaintWorklet_h | 37 #endif // WindowPaintWorklet_h |
| OLD | NEW |