| 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 #include "modules/webaudio/AudioWorkletThread.h" | 5 #include "modules/webaudio/AudioWorkletThread.h" |
| 6 | 6 |
| 7 #include <memory> |
| 7 #include "core/workers/WorkerBackingThread.h" | 8 #include "core/workers/WorkerBackingThread.h" |
| 8 #include "core/workers/WorkerThreadStartupData.h" | 9 #include "core/workers/WorkerThreadStartupData.h" |
| 9 #include "modules/webaudio/AudioWorkletGlobalScope.h" | 10 #include "modules/webaudio/AudioWorkletGlobalScope.h" |
| 10 #include "platform/CrossThreadFunctional.h" | 11 #include "platform/CrossThreadFunctional.h" |
| 11 #include "platform/WaitableEvent.h" | 12 #include "platform/WaitableEvent.h" |
| 12 #include "platform/WebThreadSupportingGC.h" | 13 #include "platform/WebThreadSupportingGC.h" |
| 13 #include "platform/instrumentation/tracing/TraceEvent.h" | 14 #include "platform/instrumentation/tracing/TraceEvent.h" |
| 14 #include "platform/weborigin/SecurityOrigin.h" | 15 #include "platform/weborigin/SecurityOrigin.h" |
| 15 #include "public/platform/Platform.h" | 16 #include "public/platform/Platform.h" |
| 16 #include "wtf/Assertions.h" | 17 #include "wtf/Assertions.h" |
| 17 #include "wtf/PtrUtil.h" | 18 #include "wtf/PtrUtil.h" |
| 18 #include <memory> | |
| 19 | 19 |
| 20 namespace blink { | 20 namespace blink { |
| 21 | 21 |
| 22 template class WorkletThreadHolder<AudioWorkletThread>; | 22 template class WorkletThreadHolder<AudioWorkletThread>; |
| 23 | 23 |
| 24 std::unique_ptr<AudioWorkletThread> AudioWorkletThread::create( | 24 std::unique_ptr<AudioWorkletThread> AudioWorkletThread::create( |
| 25 PassRefPtr<WorkerLoaderProxy> workerLoaderProxy, | 25 PassRefPtr<WorkerLoaderProxy> workerLoaderProxy, |
| 26 WorkerReportingProxy& workerReportingProxy, | 26 WorkerReportingProxy& workerReportingProxy, |
| 27 ParentFrameTaskRunners* parentFrameTaskRunners) { | 27 ParentFrameTaskRunners* parentFrameTaskRunners) { |
| 28 TRACE_EVENT0(TRACE_DISABLED_BY_DEFAULT("audio-worklet"), | 28 TRACE_EVENT0(TRACE_DISABLED_BY_DEFAULT("audio-worklet"), |
| (...skipping 61 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 90 securityOrigin->transferPrivilegesFrom( | 90 securityOrigin->transferPrivilegesFrom( |
| 91 std::move(startupData->m_starterOriginPrivilegeData)); | 91 std::move(startupData->m_starterOriginPrivilegeData)); |
| 92 } | 92 } |
| 93 | 93 |
| 94 return AudioWorkletGlobalScope::create( | 94 return AudioWorkletGlobalScope::create( |
| 95 startupData->m_scriptURL, startupData->m_userAgent, | 95 startupData->m_scriptURL, startupData->m_userAgent, |
| 96 securityOrigin.release(), this->isolate(), this); | 96 securityOrigin.release(), this->isolate(), this); |
| 97 } | 97 } |
| 98 | 98 |
| 99 } // namespace blink | 99 } // namespace blink |
| OLD | NEW |