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

Side by Side Diff: third_party/WebKit/Source/web/CompositorMutatorImpl.cpp

Issue 2204183002: Prepare CompositorWorker for per thread heap (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fix 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 #include "web/CompositorMutatorImpl.h" 5 #include "web/CompositorMutatorImpl.h"
6 6
7 #include "core/animation/CustomCompositorAnimationManager.h" 7 #include "core/animation/CustomCompositorAnimationManager.h"
8 #include "core/dom/CompositorProxy.h" 8 #include "core/dom/CompositorProxy.h"
9 #include "platform/CrossThreadFunctional.h" 9 #include "platform/CrossThreadFunctional.h"
10 #include "platform/TraceEvent.h" 10 #include "platform/TraceEvent.h"
(...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after
68 if (client->mutate(monotonicTimeNow, stateProvider)) 68 if (client->mutate(monotonicTimeNow, stateProvider))
69 needToReinvoke = true; 69 needToReinvoke = true;
70 } 70 }
71 71
72 return needToReinvoke; 72 return needToReinvoke;
73 } 73 }
74 74
75 void CompositorMutatorImpl::registerProxyClient(CompositorProxyClientImpl* clien t) 75 void CompositorMutatorImpl::registerProxyClient(CompositorProxyClientImpl* clien t)
76 { 76 {
77 TRACE_EVENT0("compositor-worker", "CompositorMutatorImpl::registerClient"); 77 TRACE_EVENT0("compositor-worker", "CompositorMutatorImpl::registerClient");
78 DCHECK(!m_proxyClients.contains(client));
78 m_proxyClients.add(client); 79 m_proxyClients.add(client);
79 setNeedsMutate(); 80 setNeedsMutate();
80 } 81 }
81 82
83 void CompositorMutatorImpl::unregisterProxyClient(CompositorProxyClientImpl* cli ent)
84 {
85 DCHECK(m_proxyClients.contains(client));
86 m_proxyClients.remove(client);
87 }
88
82 void CompositorMutatorImpl::setNeedsMutate() 89 void CompositorMutatorImpl::setNeedsMutate()
83 { 90 {
84 TRACE_EVENT0("compositor-worker", "CompositorMutatorImpl::setNeedsMutate"); 91 TRACE_EVENT0("compositor-worker", "CompositorMutatorImpl::setNeedsMutate");
85 m_client->setNeedsMutate(); 92 m_client->setNeedsMutate();
86 } 93 }
87 94
88 } // namespace blink 95 } // namespace blink
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/web/CompositorMutatorImpl.h ('k') | third_party/WebKit/Source/web/CompositorProxyClientImpl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698