OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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 CC_TEST_TEST_CONTEXT_PROVIDER_H_ | 5 #ifndef CC_TEST_TEST_CONTEXT_PROVIDER_H_ |
6 #define CC_TEST_TEST_CONTEXT_PROVIDER_H_ | 6 #define CC_TEST_TEST_CONTEXT_PROVIDER_H_ |
7 | 7 |
8 #include "base/callback.h" | 8 #include "base/callback.h" |
9 #include "base/memory/scoped_ptr.h" | 9 #include "base/memory/scoped_ptr.h" |
10 #include "base/memory/weak_ptr.h" | 10 #include "base/memory/weak_ptr.h" |
(...skipping 16 matching lines...) Expand all Loading... |
27 static scoped_refptr<TestContextProvider> Create(); | 27 static scoped_refptr<TestContextProvider> Create(); |
28 static scoped_refptr<TestContextProvider> Create( | 28 static scoped_refptr<TestContextProvider> Create( |
29 scoped_ptr<TestWebGraphicsContext3D> context); | 29 scoped_ptr<TestWebGraphicsContext3D> context); |
30 | 30 |
31 bool BindToCurrentThread() override; | 31 bool BindToCurrentThread() override; |
32 void DetachFromThread() override; | 32 void DetachFromThread() override; |
33 Capabilities ContextCapabilities() override; | 33 Capabilities ContextCapabilities() override; |
34 gpu::gles2::GLES2Interface* ContextGL() override; | 34 gpu::gles2::GLES2Interface* ContextGL() override; |
35 gpu::ContextSupport* ContextSupport() override; | 35 gpu::ContextSupport* ContextSupport() override; |
36 class GrContext* GrContext() override; | 36 class GrContext* GrContext() override; |
| 37 void InvalidateGrContext(uint32_t state) override; |
37 void SetupLock() override; | 38 void SetupLock() override; |
38 base::Lock* GetLock() override; | 39 base::Lock* GetLock() override; |
39 bool IsContextLost() override; | 40 bool IsContextLost() override; |
40 void VerifyContexts() override; | 41 void VerifyContexts() override; |
41 void DeleteCachedResources() override; | 42 void DeleteCachedResources() override; |
42 bool DestroyedOnMainThread() override; | 43 bool DestroyedOnMainThread() override; |
43 void SetLostContextCallback(const LostContextCallback& cb) override; | 44 void SetLostContextCallback(const LostContextCallback& cb) override; |
44 void SetMemoryPolicyChangedCallback( | 45 void SetMemoryPolicyChangedCallback( |
45 const MemoryPolicyChangedCallback& cb) override; | 46 const MemoryPolicyChangedCallback& cb) override; |
46 | 47 |
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
85 | 86 |
86 base::WeakPtrFactory<TestContextProvider> weak_ptr_factory_; | 87 base::WeakPtrFactory<TestContextProvider> weak_ptr_factory_; |
87 | 88 |
88 DISALLOW_COPY_AND_ASSIGN(TestContextProvider); | 89 DISALLOW_COPY_AND_ASSIGN(TestContextProvider); |
89 }; | 90 }; |
90 | 91 |
91 } // namespace cc | 92 } // namespace cc |
92 | 93 |
93 #endif // CC_TEST_TEST_CONTEXT_PROVIDER_H_ | 94 #endif // CC_TEST_TEST_CONTEXT_PROVIDER_H_ |
94 | 95 |
OLD | NEW |