| 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/CompositorWorkerThread.h" | 5 #include "modules/compositorworker/CompositorWorkerThread.h" |
| 6 | 6 |
| 7 #include "bindings/core/v8/V8GCController.h" | 7 #include "bindings/core/v8/V8GCController.h" |
| 8 #include "bindings/core/v8/V8Initializer.h" | 8 #include "bindings/core/v8/V8Initializer.h" |
| 9 #include "core/workers/InProcessWorkerObjectProxy.h" | 9 #include "core/workers/InProcessWorkerObjectProxy.h" |
| 10 #include "core/workers/WorkerBackingThread.h" | 10 #include "core/workers/WorkerBackingThread.h" |
| (...skipping 118 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 129 { | 129 { |
| 130 return *BackingThreadHolder::instance().thread(); | 130 return *BackingThreadHolder::instance().thread(); |
| 131 } | 131 } |
| 132 | 132 |
| 133 WorkerOrWorkletGlobalScope* CompositorWorkerThread::createWorkerGlobalScope(std:
:unique_ptr<WorkerThreadStartupData> startupData) | 133 WorkerOrWorkletGlobalScope* CompositorWorkerThread::createWorkerGlobalScope(std:
:unique_ptr<WorkerThreadStartupData> startupData) |
| 134 { | 134 { |
| 135 TRACE_EVENT0(TRACE_DISABLED_BY_DEFAULT("compositor-worker"), "CompositorWork
erThread::createWorkerGlobalScope"); | 135 TRACE_EVENT0(TRACE_DISABLED_BY_DEFAULT("compositor-worker"), "CompositorWork
erThread::createWorkerGlobalScope"); |
| 136 return CompositorWorkerGlobalScope::create(this, std::move(startupData), m_t
imeOrigin); | 136 return CompositorWorkerGlobalScope::create(this, std::move(startupData), m_t
imeOrigin); |
| 137 } | 137 } |
| 138 | 138 |
| 139 ConsoleMessageStorage* CompositorWorkerThread::consoleMessageStorage() | |
| 140 { | |
| 141 return toWorkerGlobalScope(globalScope())->consoleMessageStorage(); | |
| 142 } | |
| 143 | |
| 144 void CompositorWorkerThread::ensureSharedBackingThread() | 139 void CompositorWorkerThread::ensureSharedBackingThread() |
| 145 { | 140 { |
| 146 DCHECK(isMainThread()); | 141 DCHECK(isMainThread()); |
| 147 BackingThreadHolder::ensureInstance(); | 142 BackingThreadHolder::ensureInstance(); |
| 148 } | 143 } |
| 149 | 144 |
| 150 void CompositorWorkerThread::clearSharedBackingThread() | 145 void CompositorWorkerThread::clearSharedBackingThread() |
| 151 { | 146 { |
| 152 DCHECK(isMainThread()); | 147 DCHECK(isMainThread()); |
| 153 BackingThreadHolder::clear(); | 148 BackingThreadHolder::clear(); |
| 154 } | 149 } |
| 155 | 150 |
| 156 void CompositorWorkerThread::createSharedBackingThreadForTest() | 151 void CompositorWorkerThread::createSharedBackingThreadForTest() |
| 157 { | 152 { |
| 158 BackingThreadHolder::createForTest(); | 153 BackingThreadHolder::createForTest(); |
| 159 } | 154 } |
| 160 | 155 |
| 161 } // namespace blink | 156 } // namespace blink |
| OLD | NEW |