| OLD | NEW |
| 1 // Copyright 2012 The Chromium Authors. All rights reserved. | 1 // Copyright 2012 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_TREES_LAYER_TREE_HOST_CLIENT_H_ | 5 #ifndef CC_TREES_LAYER_TREE_HOST_CLIENT_H_ |
| 6 #define CC_TREES_LAYER_TREE_HOST_CLIENT_H_ | 6 #define CC_TREES_LAYER_TREE_HOST_CLIENT_H_ |
| 7 | 7 |
| 8 #include "base/memory/ref_counted.h" | 8 #include "base/memory/ref_counted.h" |
| 9 #include "base/memory/scoped_ptr.h" | 9 #include "base/memory/scoped_ptr.h" |
| 10 #include "base/time/time.h" | 10 #include "base/time/time.h" |
| (...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 42 // DidFailToInitializeOutputSurface or DidInitializeOutputSurface being | 42 // DidFailToInitializeOutputSurface or DidInitializeOutputSurface being |
| 43 // called. | 43 // called. |
| 44 virtual void RequestNewOutputSurface() = 0; | 44 virtual void RequestNewOutputSurface() = 0; |
| 45 virtual void DidInitializeOutputSurface() = 0; | 45 virtual void DidInitializeOutputSurface() = 0; |
| 46 virtual void DidFailToInitializeOutputSurface() = 0; | 46 virtual void DidFailToInitializeOutputSurface() = 0; |
| 47 virtual void WillCommit() = 0; | 47 virtual void WillCommit() = 0; |
| 48 virtual void DidCommit() = 0; | 48 virtual void DidCommit() = 0; |
| 49 virtual void DidCommitAndDrawFrame() = 0; | 49 virtual void DidCommitAndDrawFrame() = 0; |
| 50 virtual void DidCompleteSwapBuffers() = 0; | 50 virtual void DidCompleteSwapBuffers() = 0; |
| 51 | 51 |
| 52 // Called when page scale animation has completed. |
| 53 virtual void DidCompletePageScaleAnimation() = 0; |
| 54 |
| 52 // TODO(simonhong): Makes this to pure virtual function when client | 55 // TODO(simonhong): Makes this to pure virtual function when client |
| 53 // implementation is ready. | 56 // implementation is ready. |
| 54 virtual void SendBeginFramesToChildren(const BeginFrameArgs& args) {} | 57 virtual void SendBeginFramesToChildren(const BeginFrameArgs& args) {} |
| 55 | 58 |
| 56 // Requests that the client insert a rate limiting token in the shared main | 59 // Requests that the client insert a rate limiting token in the shared main |
| 57 // thread context's command stream that will block if the context gets too far | 60 // thread context's command stream that will block if the context gets too far |
| 58 // ahead of the compositor's command stream. Only needed if the tree contains | 61 // ahead of the compositor's command stream. Only needed if the tree contains |
| 59 // a TextureLayer that calls SetRateLimitContext(true). | 62 // a TextureLayer that calls SetRateLimitContext(true). |
| 60 virtual void RateLimitSharedMainThreadContext() {} | 63 virtual void RateLimitSharedMainThreadContext() {} |
| 61 | 64 |
| 62 protected: | 65 protected: |
| 63 virtual ~LayerTreeHostClient() {} | 66 virtual ~LayerTreeHostClient() {} |
| 64 }; | 67 }; |
| 65 | 68 |
| 66 } // namespace cc | 69 } // namespace cc |
| 67 | 70 |
| 68 #endif // CC_TREES_LAYER_TREE_HOST_CLIENT_H_ | 71 #endif // CC_TREES_LAYER_TREE_HOST_CLIENT_H_ |
| OLD | NEW |