Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(64)

Side by Side Diff: content/browser/frame_host/render_widget_host_view_child_frame.h

Issue 2144733005: [WIP] cc: Plumb SurfaceId from clients Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Ensure only SurfaceFactoy and tests can update hierarchy Created 4 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 CONTENT_BROWSER_FRAME_HOST_RENDER_WIDGET_HOST_VIEW_CHILD_FRAME_H_ 5 #ifndef CONTENT_BROWSER_FRAME_HOST_RENDER_WIDGET_HOST_VIEW_CHILD_FRAME_H_
6 #define CONTENT_BROWSER_FRAME_HOST_RENDER_WIDGET_HOST_VIEW_CHILD_FRAME_H_ 6 #define CONTENT_BROWSER_FRAME_HOST_RENDER_WIDGET_HOST_VIEW_CHILD_FRAME_H_
7 7
8 #include <stddef.h> 8 #include <stddef.h>
9 #include <stdint.h> 9 #include <stdint.h>
10 10
(...skipping 99 matching lines...) Expand 10 before | Expand all | Expand 10 after
110 const SkColorType preferred_color_type) override; 110 const SkColorType preferred_color_type) override;
111 void CopyFromCompositingSurfaceToVideoFrame( 111 void CopyFromCompositingSurfaceToVideoFrame(
112 const gfx::Rect& src_subrect, 112 const gfx::Rect& src_subrect,
113 const scoped_refptr<media::VideoFrame>& target, 113 const scoped_refptr<media::VideoFrame>& target,
114 const base::Callback<void(const gfx::Rect&, bool)>& callback) override; 114 const base::Callback<void(const gfx::Rect&, bool)>& callback) override;
115 bool CanCopyToVideoFrame() const override; 115 bool CanCopyToVideoFrame() const override;
116 bool HasAcceleratedSurface(const gfx::Size& desired_size) override; 116 bool HasAcceleratedSurface(const gfx::Size& desired_size) override;
117 void GestureEventAck(const blink::WebGestureEvent& event, 117 void GestureEventAck(const blink::WebGestureEvent& event,
118 InputEventAckState ack_result) override; 118 InputEventAckState ack_result) override;
119 void OnSwapCompositorFrame(uint32_t output_surface_id, 119 void OnSwapCompositorFrame(uint32_t output_surface_id,
120 const cc::SurfaceId& surface_id,
120 cc::CompositorFrame frame) override; 121 cc::CompositorFrame frame) override;
121 // Since the URL of content rendered by this class is not displayed in 122 // Since the URL of content rendered by this class is not displayed in
122 // the URL bar, this method does not need an implementation. 123 // the URL bar, this method does not need an implementation.
123 void ClearCompositorFrame() override {} 124 void ClearCompositorFrame() override {}
124 void GetScreenInfo(blink::WebScreenInfo* results) override; 125 void GetScreenInfo(blink::WebScreenInfo* results) override;
125 gfx::Rect GetBoundsInRootWindow() override; 126 gfx::Rect GetBoundsInRootWindow() override;
126 void ProcessAckedTouchEvent(const TouchEventWithLatencyInfo& touch, 127 void ProcessAckedTouchEvent(const TouchEventWithLatencyInfo& touch,
127 InputEventAckState ack_result) override; 128 InputEventAckState ack_result) override;
128 bool LockMouse() override; 129 bool LockMouse() override;
129 void UnlockMouse() override; 130 void UnlockMouse() override;
(...skipping 63 matching lines...) Expand 10 before | Expand all | Expand 10 after
193 void ProcessFrameSwappedCallbacks(); 194 void ProcessFrameSwappedCallbacks();
194 195
195 // The last scroll offset of the view. 196 // The last scroll offset of the view.
196 gfx::Vector2dF last_scroll_offset_; 197 gfx::Vector2dF last_scroll_offset_;
197 198
198 // Members will become private when RenderWidgetHostViewGuest is removed. 199 // Members will become private when RenderWidgetHostViewGuest is removed.
199 // The model object. 200 // The model object.
200 RenderWidgetHostImpl* host_; 201 RenderWidgetHostImpl* host_;
201 202
202 // Surface-related state. 203 // Surface-related state.
203 std::unique_ptr<cc::SurfaceIdAllocator> id_allocator_;
204 std::unique_ptr<cc::SurfaceFactory> surface_factory_; 204 std::unique_ptr<cc::SurfaceFactory> surface_factory_;
205 uint32_t surface_client_id_;
205 cc::SurfaceId surface_id_; 206 cc::SurfaceId surface_id_;
206 uint32_t next_surface_sequence_; 207 uint32_t next_surface_sequence_;
207 uint32_t last_output_surface_id_; 208 uint32_t last_output_surface_id_;
208 gfx::Size current_surface_size_; 209 gfx::Size current_surface_size_;
209 float current_surface_scale_factor_; 210 float current_surface_scale_factor_;
210 gfx::Rect last_screen_rect_; 211 gfx::Rect last_screen_rect_;
211 uint32_t ack_pending_count_; 212 uint32_t ack_pending_count_;
212 cc::ReturnedResourceArray surface_returned_resources_; 213 cc::ReturnedResourceArray surface_returned_resources_;
213 214
214 // frame_connector_ provides a platform abstraction. Messages 215 // frame_connector_ provides a platform abstraction. Messages
(...skipping 22 matching lines...) Expand all
237 // The surface client ID of the parent RenderWidgetHostView. 0 if none. 238 // The surface client ID of the parent RenderWidgetHostView. 0 if none.
238 uint32_t parent_surface_client_id_; 239 uint32_t parent_surface_client_id_;
239 240
240 base::WeakPtrFactory<RenderWidgetHostViewChildFrame> weak_factory_; 241 base::WeakPtrFactory<RenderWidgetHostViewChildFrame> weak_factory_;
241 DISALLOW_COPY_AND_ASSIGN(RenderWidgetHostViewChildFrame); 242 DISALLOW_COPY_AND_ASSIGN(RenderWidgetHostViewChildFrame);
242 }; 243 };
243 244
244 } // namespace content 245 } // namespace content
245 246
246 #endif // CONTENT_BROWSER_FRAME_HOST_RENDER_WIDGET_HOST_VIEW_CHILD_FRAME_H_ 247 #endif // CONTENT_BROWSER_FRAME_HOST_RENDER_WIDGET_HOST_VIEW_CHILD_FRAME_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698