Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(64)

Side by Side Diff: third_party/WebKit/Source/modules/compositorworker/CompositorWorkerThread.cpp

Issue 1897193002: Worker: Rename worker components to clarify what they work for (part 2) (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
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/WorkerBackingThread.h" 10 #include "core/workers/WorkerBackingThread.h"
10 #include "core/workers/WorkerObjectProxy.h"
11 #include "core/workers/WorkerThreadStartupData.h" 11 #include "core/workers/WorkerThreadStartupData.h"
12 #include "modules/compositorworker/CompositorWorkerGlobalScope.h" 12 #include "modules/compositorworker/CompositorWorkerGlobalScope.h"
13 #include "platform/ThreadSafeFunctional.h" 13 #include "platform/ThreadSafeFunctional.h"
14 #include "platform/TraceEvent.h" 14 #include "platform/TraceEvent.h"
15 #include "public/platform/Platform.h" 15 #include "public/platform/Platform.h"
16 16
17 namespace blink { 17 namespace blink {
18 18
19 namespace { 19 namespace {
20 20
(...skipping 14 matching lines...) Expand all
35 } 35 }
36 36
37 private: 37 private:
38 BackingThreadHolder() : m_thread(WorkerBackingThread::create(Platform::curre nt()->compositorThread())) {} 38 BackingThreadHolder() : m_thread(WorkerBackingThread::create(Platform::curre nt()->compositorThread())) {}
39 39
40 OwnPtr<WorkerBackingThread> m_thread; 40 OwnPtr<WorkerBackingThread> m_thread;
41 }; 41 };
42 42
43 } // namespace 43 } // namespace
44 44
45 PassOwnPtr<CompositorWorkerThread> CompositorWorkerThread::create(PassRefPtr<Wor kerLoaderProxy> workerLoaderProxy, WorkerObjectProxy& workerObjectProxy, double timeOrigin) 45 PassOwnPtr<CompositorWorkerThread> CompositorWorkerThread::create(PassRefPtr<Wor kerLoaderProxy> workerLoaderProxy, InProcessWorkerObjectProxy& workerObjectProxy , double timeOrigin)
46 { 46 {
47 TRACE_EVENT0(TRACE_DISABLED_BY_DEFAULT("compositor-worker"), "CompositorWork erThread::create"); 47 TRACE_EVENT0(TRACE_DISABLED_BY_DEFAULT("compositor-worker"), "CompositorWork erThread::create");
48 ASSERT(isMainThread()); 48 ASSERT(isMainThread());
49 return adoptPtr(new CompositorWorkerThread(workerLoaderProxy, workerObjectPr oxy, timeOrigin)); 49 return adoptPtr(new CompositorWorkerThread(workerLoaderProxy, workerObjectPr oxy, timeOrigin));
50 } 50 }
51 51
52 CompositorWorkerThread::CompositorWorkerThread(PassRefPtr<WorkerLoaderProxy> wor kerLoaderProxy, WorkerObjectProxy& workerObjectProxy, double timeOrigin) 52 CompositorWorkerThread::CompositorWorkerThread(PassRefPtr<WorkerLoaderProxy> wor kerLoaderProxy, InProcessWorkerObjectProxy& workerObjectProxy, double timeOrigin )
53 : WorkerThread(workerLoaderProxy, workerObjectProxy) 53 : WorkerThread(workerLoaderProxy, workerObjectProxy)
54 , m_workerObjectProxy(workerObjectProxy) 54 , m_workerObjectProxy(workerObjectProxy)
55 , m_timeOrigin(timeOrigin) 55 , m_timeOrigin(timeOrigin)
56 { 56 {
57 } 57 }
58 58
59 CompositorWorkerThread::~CompositorWorkerThread() 59 CompositorWorkerThread::~CompositorWorkerThread()
60 { 60 {
61 } 61 }
62 62
(...skipping 12 matching lines...) Expand all
75 { 75 {
76 BackingThreadHolder::instance().clear(); 76 BackingThreadHolder::instance().clear();
77 } 77 }
78 78
79 void CompositorWorkerThread::resetSharedBackingThreadForTest() 79 void CompositorWorkerThread::resetSharedBackingThreadForTest()
80 { 80 {
81 BackingThreadHolder::instance().resetForTest(); 81 BackingThreadHolder::instance().resetForTest();
82 } 82 }
83 83
84 } // namespace blink 84 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698