| 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 49 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 60 WindowAndroidCompositor* compositor, | 60 WindowAndroidCompositor* compositor, |
| 61 const gfx::Rect& src_subrect_in_pixel, | 61 const gfx::Rect& src_subrect_in_pixel, |
| 62 cc::CopyOutputRequest::CopyOutputRequestCallback result_callback); | 62 cc::CopyOutputRequest::CopyOutputRequestCallback result_callback); |
| 63 | 63 |
| 64 void CompositorFrameSinkChanged(); | 64 void CompositorFrameSinkChanged(); |
| 65 | 65 |
| 66 void UpdateBackgroundColor(SkColor color); | 66 void UpdateBackgroundColor(SkColor color); |
| 67 | 67 |
| 68 void UpdateContainerSizeinDIP(const gfx::Size& size_in_dip); | 68 void UpdateContainerSizeinDIP(const gfx::Size& size_in_dip); |
| 69 | 69 |
| 70 // Called when this DFH is attached/detached from a parent browser compositor | |
| 71 // and needs to be attached to the surface hierarchy. | |
| 72 void RegisterFrameSinkHierarchy(const cc::FrameSinkId& parent_id); | |
| 73 void UnregisterFrameSinkHierarchy(); | |
| 74 | |
| 75 private: | 70 private: |
| 76 // cc::SurfaceFactoryClient implementation. | 71 // cc::SurfaceFactoryClient implementation. |
| 77 void ReturnResources(const cc::ReturnedResourceArray& resources) override; | 72 void ReturnResources(const cc::ReturnedResourceArray& resources) override; |
| 78 void SetBeginFrameSource(cc::BeginFrameSource* begin_frame_source) override; | 73 void SetBeginFrameSource(cc::BeginFrameSource* begin_frame_source) override; |
| 79 | 74 |
| 80 void UpdateBackgroundLayer(); | 75 void UpdateBackgroundLayer(); |
| 81 | 76 |
| 82 const cc::FrameSinkId frame_sink_id_; | 77 const cc::FrameSinkId frame_sink_id_; |
| 83 | 78 |
| 84 ViewAndroid* view_; | 79 ViewAndroid* view_; |
| (...skipping 25 matching lines...) Expand all Loading... |
| 110 scoped_refptr<cc::Layer> background_layer_; | 105 scoped_refptr<cc::Layer> background_layer_; |
| 111 | 106 |
| 112 gfx::Size container_size_in_dip_; | 107 gfx::Size container_size_in_dip_; |
| 113 | 108 |
| 114 DISALLOW_COPY_AND_ASSIGN(DelegatedFrameHostAndroid); | 109 DISALLOW_COPY_AND_ASSIGN(DelegatedFrameHostAndroid); |
| 115 }; | 110 }; |
| 116 | 111 |
| 117 } // namespace ui | 112 } // namespace ui |
| 118 | 113 |
| 119 #endif // UI_ANDROID_DELEGATED_FRAME_HOST_ANDROID_H_ | 114 #endif // UI_ANDROID_DELEGATED_FRAME_HOST_ANDROID_H_ |
| OLD | NEW |