OLD | NEW |
1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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_CHANNEL_IMPL_H_ | 5 #ifndef CC_TREES_CHANNEL_IMPL_H_ |
6 #define CC_TREES_CHANNEL_IMPL_H_ | 6 #define CC_TREES_CHANNEL_IMPL_H_ |
7 | 7 |
8 #include "cc/base/cc_export.h" | 8 #include "cc/base/cc_export.h" |
9 #include "cc/debug/frame_timing_tracker.h" | 9 #include "cc/debug/frame_timing_tracker.h" |
10 #include "cc/output/renderer_capabilities.h" | 10 #include "cc/output/renderer_capabilities.h" |
11 #include "cc/trees/proxy_common.h" | 11 #include "cc/trees/proxy_common.h" |
12 | 12 |
13 namespace cc { | 13 namespace cc { |
14 | 14 |
15 class AnimationEvents; | 15 class AnimationEvents; |
16 | 16 |
17 // Channel used to send commands to and receive commands from ProxyMain. | 17 // Channel used to send commands to and receive commands from ProxyMain. |
18 // The ChannelImpl implementation creates and owns ProxyImpl on receiving the | 18 // The ChannelImpl implementation creates and owns ProxyImpl on receiving the |
19 // InitializeImpl call from ChannelMain. | 19 // InitializeImpl call from ChannelMain. |
20 // See channel_main.h | 20 // See channel_main.h |
21 class CC_EXPORT ChannelImpl { | 21 class CC_EXPORT ChannelImpl { |
22 public: | 22 public: |
23 // Interface for commands sent to ProxyMain | 23 // Interface for commands sent to ProxyMain |
24 virtual void DidCompleteSwapBuffers() = 0; | 24 virtual void DidCompleteSwapBuffers() = 0; |
25 virtual void SetRendererCapabilitiesMainCopy( | 25 virtual void SetRendererCapabilitiesMainCopy( |
26 const RendererCapabilities& capabilities) = 0; | 26 const RendererCapabilities& capabilities) = 0; |
27 virtual void BeginMainFrameNotExpectedSoon() = 0; | 27 virtual void BeginMainFrameNotExpectedSoon() = 0; |
28 virtual void DidCommitAndDrawFrame() = 0; | 28 virtual void DidCommitAndDrawFrame() = 0; |
29 virtual void SetAnimationEvents(scoped_ptr<AnimationEvents> queue) = 0; | 29 virtual void SetAnimationEvents(std::unique_ptr<AnimationEvents> queue) = 0; |
30 virtual void DidLoseOutputSurface() = 0; | 30 virtual void DidLoseOutputSurface() = 0; |
31 virtual void RequestNewOutputSurface() = 0; | 31 virtual void RequestNewOutputSurface() = 0; |
32 virtual void DidInitializeOutputSurface( | 32 virtual void DidInitializeOutputSurface( |
33 bool success, | 33 bool success, |
34 const RendererCapabilities& capabilities) = 0; | 34 const RendererCapabilities& capabilities) = 0; |
35 virtual void DidCompletePageScaleAnimation() = 0; | 35 virtual void DidCompletePageScaleAnimation() = 0; |
36 virtual void PostFrameTimingEventsOnMain( | 36 virtual void PostFrameTimingEventsOnMain( |
37 scoped_ptr<FrameTimingTracker::CompositeTimingSet> composite_events, | 37 std::unique_ptr<FrameTimingTracker::CompositeTimingSet> composite_events, |
38 scoped_ptr<FrameTimingTracker::MainFrameTimingSet> main_frame_events) = 0; | 38 std::unique_ptr<FrameTimingTracker::MainFrameTimingSet> |
| 39 main_frame_events) = 0; |
39 virtual void BeginMainFrame( | 40 virtual void BeginMainFrame( |
40 scoped_ptr<BeginMainFrameAndCommitState> begin_main_frame_state) = 0; | 41 std::unique_ptr<BeginMainFrameAndCommitState> begin_main_frame_state) = 0; |
41 | 42 |
42 protected: | 43 protected: |
43 virtual ~ChannelImpl() {} | 44 virtual ~ChannelImpl() {} |
44 }; | 45 }; |
45 | 46 |
46 } // namespace cc | 47 } // namespace cc |
47 | 48 |
48 #endif // CC_TREES_CHANNEL_IMPL_H_ | 49 #endif // CC_TREES_CHANNEL_IMPL_H_ |
OLD | NEW |