OLD | NEW |
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 #ifndef UI_ANDROID_DELEGATED_FRAME_HOST_ANDROID_H_ | 5 #ifndef UI_ANDROID_DELEGATED_FRAME_HOST_ANDROID_H_ |
6 #define UI_ANDROID_DELEGATED_FRAME_HOST_ANDROID_H_ | 6 #define UI_ANDROID_DELEGATED_FRAME_HOST_ANDROID_H_ |
7 | 7 |
8 #include "base/macros.h" | 8 #include "base/macros.h" |
9 #include "base/memory/ref_counted.h" | 9 #include "base/memory/ref_counted.h" |
10 #include "cc/output/copy_output_request.h" | 10 #include "cc/output/copy_output_request.h" |
(...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
66 // Called when this DFH is attached/detached from a parent browser compositor | 66 // Called when this DFH is attached/detached from a parent browser compositor |
67 // and needs to be attached to the surface hierarchy. | 67 // and needs to be attached to the surface hierarchy. |
68 void AttachToCompositor(WindowAndroidCompositor* compositor); | 68 void AttachToCompositor(WindowAndroidCompositor* compositor); |
69 void DetachFromCompositor(); | 69 void DetachFromCompositor(); |
70 | 70 |
71 // Returns the ID for the current Surface. | 71 // Returns the ID for the current Surface. |
72 cc::SurfaceId SurfaceId() const; | 72 cc::SurfaceId SurfaceId() const; |
73 | 73 |
74 private: | 74 private: |
75 // cc::CompositorFrameSinkSupportClient implementation. | 75 // cc::CompositorFrameSinkSupportClient implementation. |
76 void DidReceiveCompositorFrameAck() override; | 76 void DidReceiveCompositorFrameAck( |
| 77 const cc::ReturnedResourceArray& resources) override; |
77 void OnBeginFrame(const cc::BeginFrameArgs& args) override; | 78 void OnBeginFrame(const cc::BeginFrameArgs& args) override; |
78 void ReclaimResources(const cc::ReturnedResourceArray& resources) override; | 79 void ReclaimResources(const cc::ReturnedResourceArray& resources) override; |
79 void WillDrawSurface(const cc::LocalSurfaceId& local_surface_id, | 80 void WillDrawSurface(const cc::LocalSurfaceId& local_surface_id, |
80 const gfx::Rect& damage_rect) override; | 81 const gfx::Rect& damage_rect) override; |
81 | 82 |
82 // cc::ExternalBeginFrameSourceClient implementation. | 83 // cc::ExternalBeginFrameSourceClient implementation. |
83 void OnNeedsBeginFrames(bool needs_begin_frames) override; | 84 void OnNeedsBeginFrames(bool needs_begin_frames) override; |
84 void OnDidFinishFrame(const cc::BeginFrameAck& ack) override; | 85 void OnDidFinishFrame(const cc::BeginFrameAck& ack) override; |
85 | 86 |
86 void CreateNewCompositorFrameSinkSupport(); | 87 void CreateNewCompositorFrameSinkSupport(); |
(...skipping 13 matching lines...) Expand all Loading... |
100 bool has_transparent_background_ = false; | 101 bool has_transparent_background_ = false; |
101 | 102 |
102 scoped_refptr<cc::SurfaceLayer> content_layer_; | 103 scoped_refptr<cc::SurfaceLayer> content_layer_; |
103 | 104 |
104 DISALLOW_COPY_AND_ASSIGN(DelegatedFrameHostAndroid); | 105 DISALLOW_COPY_AND_ASSIGN(DelegatedFrameHostAndroid); |
105 }; | 106 }; |
106 | 107 |
107 } // namespace ui | 108 } // namespace ui |
108 | 109 |
109 #endif // UI_ANDROID_DELEGATED_FRAME_HOST_ANDROID_H_ | 110 #endif // UI_ANDROID_DELEGATED_FRAME_HOST_ANDROID_H_ |
OLD | NEW |