| OLD | NEW |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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 #include "modules/compositorworker/CompositorWorker.h" | 5 #include "modules/compositorworker/CompositorWorker.h" |
| 6 | 6 |
| 7 #include "bindings/core/v8/ExceptionState.h" | 7 #include "bindings/core/v8/ExceptionState.h" |
| 8 #include "core/dom/CompositorProxyClient.h" | 8 #include "core/dom/CompositorProxyClientFactory.h" |
| 9 #include "core/dom/CompositorWorkerProxyClient.h" |
| 9 #include "core/dom/Document.h" | 10 #include "core/dom/Document.h" |
| 10 #include "core/dom/ExceptionCode.h" | 11 #include "core/dom/ExceptionCode.h" |
| 11 #include "core/frame/LocalFrame.h" | 12 #include "core/frame/LocalFrame.h" |
| 12 #include "core/page/ChromeClient.h" | 13 #include "core/page/ChromeClient.h" |
| 13 #include "core/workers/WorkerClients.h" | 14 #include "core/workers/WorkerClients.h" |
| 14 #include "modules/EventTargetModules.h" | 15 #include "modules/EventTargetModules.h" |
| 15 #include "modules/compositorworker/CompositorWorkerMessagingProxy.h" | 16 #include "modules/compositorworker/CompositorWorkerMessagingProxy.h" |
| 16 #include "modules/compositorworker/CompositorWorkerThread.h" | 17 #include "modules/compositorworker/CompositorWorkerThread.h" |
| 17 | 18 |
| 18 namespace blink { | 19 namespace blink { |
| (...skipping 29 matching lines...) Expand all Loading... |
| 48 | 49 |
| 49 const AtomicString& CompositorWorker::interfaceName() const { | 50 const AtomicString& CompositorWorker::interfaceName() const { |
| 50 return EventTargetNames::CompositorWorker; | 51 return EventTargetNames::CompositorWorker; |
| 51 } | 52 } |
| 52 | 53 |
| 53 InProcessWorkerMessagingProxy* | 54 InProcessWorkerMessagingProxy* |
| 54 CompositorWorker::createInProcessWorkerMessagingProxy( | 55 CompositorWorker::createInProcessWorkerMessagingProxy( |
| 55 ExecutionContext* context) { | 56 ExecutionContext* context) { |
| 56 Document* document = toDocument(context); | 57 Document* document = toDocument(context); |
| 57 WorkerClients* workerClients = WorkerClients::create(); | 58 WorkerClients* workerClients = WorkerClients::create(); |
| 58 provideCompositorProxyClientTo( | 59 CompositorWorkerProxyClient* client = |
| 59 workerClients, | 60 static_cast<CompositorWorkerProxyClient*>( |
| 60 document->frame()->chromeClient().createCompositorProxyClient( | 61 document->frame() |
| 61 document->frame())); | 62 ->chromeClient() |
| 63 .compositorProxyClientFactory(document->frame()) |
| 64 ->create(CompositorProxyClient::kWorkerClient)); |
| 65 provideCompositorWorkerProxyClientTo(workerClients, client); |
| 62 return new CompositorWorkerMessagingProxy(this, workerClients); | 66 return new CompositorWorkerMessagingProxy(this, workerClients); |
| 63 } | 67 } |
| 64 | 68 |
| 65 } // namespace blink | 69 } // namespace blink |
| OLD | NEW |