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

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

Issue 2171973002: [WIP][worklets] ThreadedWorkletGlobalScope + AnimationWorkletGlobalScope Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: ...... Created 4 years, 3 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 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 WebMemoryPressureLevel_h 5 #include "modules/compositorworker/AnimationWorkletGlobalScopeProxy.h"
6 #define WebMemoryPressureLevel_h 6
7 #include "core/workers/ThreadedWorkletMessagingProxy.h"
8 #include "core/workers/ThreadedWorkletObjectProxy.h"
9 #include "modules/compositorworker/AnimationWorkletThread.h"
7 10
8 namespace blink { 11 namespace blink {
9 12
10 // These number must correspond to 13 AnimationWorkletGlobalScopeProxy::AnimationWorkletGlobalScopeProxy(LocalFrame* f rame)
11 // base::MemoryPressureListener::MemoryPressureLevel. 14 : ThreadedWorkletMessagingProxy(frame)
12 enum WebMemoryPressureLevel { 15 {
13 WebMemoryPressureLevelNone, 16 }
14 WebMemoryPressureLevelModerate, 17
15 WebMemoryPressureLevelCritical, 18 AnimationWorkletGlobalScopeProxy::~AnimationWorkletGlobalScopeProxy()
16 }; 19 {
20 }
21
22 std::unique_ptr<WorkerThread> AnimationWorkletGlobalScopeProxy::createWorkerThre ad()
23 {
24 return AnimationWorkletThread::create(loaderProxy(), workerObjectProxy());
25 }
17 26
18 } // namespace blink 27 } // namespace blink
19
20 #endif
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698