| 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 CompositorWorkerProxyClient_h | 5 #ifndef CompositorWorkerProxyClient_h |
| 6 #define CompositorWorkerProxyClient_h | 6 #define CompositorWorkerProxyClient_h |
| 7 | 7 |
| 8 #include "core/CoreExport.h" | 8 #include "core/CoreExport.h" |
| 9 #include "core/dom/CompositorProxyClient.h" | 9 #include "core/dom/CompositorProxyClient.h" |
| 10 #include "core/workers/WorkerClients.h" | 10 #include "core/workers/WorkerClients.h" |
| 11 #include "wtf/Noncopyable.h" | 11 #include "wtf/Noncopyable.h" |
| 12 | 12 |
| 13 namespace blink { | 13 namespace blink { |
| 14 | 14 |
| 15 class WorkerClients; | 15 class WorkerClients; |
| 16 class WorkerGlobalScope; | 16 class WorkerGlobalScope; |
| 17 | 17 |
| 18 class CORE_EXPORT CompositorWorkerProxyClient | 18 class CORE_EXPORT CompositorWorkerProxyClient |
| 19 : public CompositorProxyClient, | 19 : public Supplement<WorkerClients> { |
| 20 public Supplement<WorkerClients> { | |
| 21 WTF_MAKE_NONCOPYABLE(CompositorWorkerProxyClient); | 20 WTF_MAKE_NONCOPYABLE(CompositorWorkerProxyClient); |
| 22 USING_GARBAGE_COLLECTED_MIXIN(CompositorWorkerProxyClient); | |
| 23 | 21 |
| 24 public: | 22 public: |
| 25 CompositorWorkerProxyClient() {} | 23 CompositorWorkerProxyClient() {} |
| 26 DEFINE_INLINE_VIRTUAL_TRACE() { | |
| 27 CompositorProxyClient::trace(visitor); | |
| 28 Supplement<WorkerClients>::trace(visitor); | |
| 29 } | |
| 30 | 24 |
| 31 static CompositorWorkerProxyClient* from(WorkerClients*); | 25 static CompositorWorkerProxyClient* from(WorkerClients*); |
| 32 static const char* supplementName(); | 26 static const char* supplementName(); |
| 33 | 27 |
| 34 virtual void dispose() = 0; | 28 virtual void dispose() = 0; |
| 35 virtual void setGlobalScope(WorkerGlobalScope*) = 0; | 29 virtual void setGlobalScope(WorkerGlobalScope*) = 0; |
| 36 virtual void requestAnimationFrame() = 0; | 30 virtual void requestAnimationFrame() = 0; |
| 31 virtual CompositorProxyClient* compositorProxyClient() = 0; |
| 37 }; | 32 }; |
| 38 | 33 |
| 39 CORE_EXPORT void provideCompositorWorkerProxyClientTo( | 34 CORE_EXPORT void provideCompositorWorkerProxyClientTo( |
| 40 WorkerClients*, | 35 WorkerClients*, |
| 41 CompositorWorkerProxyClient*); | 36 CompositorWorkerProxyClient*); |
| 42 | 37 |
| 43 } // namespace blink | 38 } // namespace blink |
| 44 | 39 |
| 45 #endif // CompositorWorkerProxyClient_h | 40 #endif // CompositorWorkerProxyClient_h |
| OLD | NEW |