Chromium Code Reviews| Index: cc/output/output_surface.h |
| diff --git a/cc/output/output_surface.h b/cc/output/output_surface.h |
| index 9611ef4406e0fd18514c89a585d40f9f898085f2..ea68fa0f0dbacbc55ab89b389795425005c9015e 100644 |
| --- a/cc/output/output_surface.h |
| +++ b/cc/output/output_surface.h |
| @@ -11,6 +11,7 @@ |
| #include "base/memory/ref_counted.h" |
| #include "base/memory/scoped_ptr.h" |
| #include "base/memory/weak_ptr.h" |
| +#include "base/threading/thread_checker.h" |
| #include "cc/base/cc_export.h" |
| #include "cc/output/context_provider.h" |
| #include "cc/output/overlay_candidate_validator.h" |
| @@ -112,9 +113,14 @@ class CC_EXPORT OutputSurface { |
| // Called by the compositor on the compositor thread. This is a place where |
| // thread-specific data for the output surface can be initialized, since from |
| - // this point on the output surface will only be used on the compositor |
| - // thread. |
| + // this point to when DetachFromClient() is called the output surface will |
| + // only be used on the compositor thread. |
| virtual bool BindToClient(OutputSurfaceClient* client); |
| + // Called by the compositor on the compositor thread. This is a place where |
|
danakj
2015/09/12 00:09:14
nit: whitespace before the comment please
reveman
2015/09/12 12:49:57
Done.
|
| + // thread-specific data for the output surface can be uninitialized. |
| + virtual void DetachFromClient(); |
| + |
| + bool CalledOnValidClientThread(); |
|
danakj
2015/09/12 00:09:14
Do we need a public method?
reveman
2015/09/12 12:49:57
Good point. Removed.
|
| virtual void EnsureBackbuffer(); |
| virtual void DiscardBackbuffer(); |
| @@ -193,6 +199,7 @@ class CC_EXPORT OutputSurface { |
| private: |
| bool external_stencil_test_enabled_; |
| + base::ThreadChecker client_thread_checker_; |
|
danakj
2015/09/12 00:09:14
just make this protected?
reveman
2015/09/12 12:49:57
Done.
|
| base::WeakPtrFactory<OutputSurface> weak_ptr_factory_; |