OLD | NEW |
---|---|
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 #include "content/browser/frame_host/render_widget_host_view_child_frame.h" | 5 #include "content/browser/frame_host/render_widget_host_view_child_frame.h" |
6 | 6 |
7 #include <algorithm> | 7 #include <algorithm> |
8 #include <utility> | 8 #include <utility> |
9 #include <vector> | 9 #include <vector> |
10 | 10 |
(...skipping 350 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
361 CreateCompositorFrameSinkSupport(); | 361 CreateCompositorFrameSinkSupport(); |
362 has_frame_ = false; | 362 has_frame_ = false; |
363 } | 363 } |
364 | 364 |
365 void RenderWidgetHostViewChildFrame::ProcessCompositorFrame( | 365 void RenderWidgetHostViewChildFrame::ProcessCompositorFrame( |
366 const cc::LocalSurfaceId& local_surface_id, | 366 const cc::LocalSurfaceId& local_surface_id, |
367 cc::CompositorFrame frame) { | 367 cc::CompositorFrame frame) { |
368 current_surface_size_ = frame.render_pass_list.back()->output_rect.size(); | 368 current_surface_size_ = frame.render_pass_list.back()->output_rect.size(); |
369 current_surface_scale_factor_ = frame.metadata.device_scale_factor; | 369 current_surface_scale_factor_ = frame.metadata.device_scale_factor; |
370 | 370 |
371 support_->SubmitCompositorFrame(local_surface_id, std::move(frame)); | 371 DCHECK(support_->SubmitCompositorFrame(local_surface_id, std::move(frame))); |
danakj
2017/05/19 19:00:59
and here
Saman Sami
2017/05/19 19:26:46
Done.
| |
372 has_frame_ = true; | 372 has_frame_ = true; |
373 | 373 |
374 if (local_surface_id_ != local_surface_id || HasEmbedderChanged()) { | 374 if (local_surface_id_ != local_surface_id || HasEmbedderChanged()) { |
375 local_surface_id_ = local_surface_id; | 375 local_surface_id_ = local_surface_id; |
376 SendSurfaceInfoToEmbedder(); | 376 SendSurfaceInfoToEmbedder(); |
377 } | 377 } |
378 | 378 |
379 ProcessFrameSwappedCallbacks(); | 379 ProcessFrameSwappedCallbacks(); |
380 } | 380 } |
381 | 381 |
(...skipping 342 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
724 frame_sink_id_); | 724 frame_sink_id_); |
725 } | 725 } |
726 support_.reset(); | 726 support_.reset(); |
727 } | 727 } |
728 | 728 |
729 bool RenderWidgetHostViewChildFrame::HasEmbedderChanged() { | 729 bool RenderWidgetHostViewChildFrame::HasEmbedderChanged() { |
730 return false; | 730 return false; |
731 } | 731 } |
732 | 732 |
733 } // namespace content | 733 } // namespace content |
OLD | NEW |