| 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 "mojo/services/html_viewer/weblayertreeview_impl.h" | 5 #include "mojo/services/html_viewer/weblayertreeview_impl.h" |
| 6 | 6 |
| 7 #include "base/message_loop/message_loop_proxy.h" | 7 #include "base/message_loop/message_loop_proxy.h" |
| 8 #include "cc/blink/web_layer_impl.h" | 8 #include "cc/blink/web_layer_impl.h" |
| 9 #include "cc/layers/layer.h" | 9 #include "cc/layers/layer.h" |
| 10 #include "cc/output/begin_frame_args.h" | 10 #include "cc/output/begin_frame_args.h" |
| (...skipping 79 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 90 top_controls_delta); | 90 top_controls_delta); |
| 91 } | 91 } |
| 92 | 92 |
| 93 void WebLayerTreeViewImpl::ApplyViewportDeltas( | 93 void WebLayerTreeViewImpl::ApplyViewportDeltas( |
| 94 const gfx::Vector2d& scroll_delta, | 94 const gfx::Vector2d& scroll_delta, |
| 95 float page_scale, | 95 float page_scale, |
| 96 float top_controls_delta) { | 96 float top_controls_delta) { |
| 97 widget_->applyViewportDeltas(scroll_delta, page_scale, top_controls_delta); | 97 widget_->applyViewportDeltas(scroll_delta, page_scale, top_controls_delta); |
| 98 } | 98 } |
| 99 | 99 |
| 100 void WebLayerTreeViewImpl::RequestNewOutputSurface(bool fallback) { | 100 void WebLayerTreeViewImpl::RequestNewOutputSurface() { |
| 101 layer_tree_host_->SetOutputSurface(output_surface_.Pass()); | 101 layer_tree_host_->SetOutputSurface(output_surface_.Pass()); |
| 102 } | 102 } |
| 103 | 103 |
| 104 void WebLayerTreeViewImpl::DidFailToInitializeOutputSurface() { |
| 105 RequestNewOutputSurface(); |
| 106 } |
| 107 |
| 104 void WebLayerTreeViewImpl::DidInitializeOutputSurface() { | 108 void WebLayerTreeViewImpl::DidInitializeOutputSurface() { |
| 105 } | 109 } |
| 106 | 110 |
| 107 void WebLayerTreeViewImpl::WillCommit() { | 111 void WebLayerTreeViewImpl::WillCommit() { |
| 108 } | 112 } |
| 109 | 113 |
| 110 void WebLayerTreeViewImpl::DidCommit() { | 114 void WebLayerTreeViewImpl::DidCommit() { |
| 111 } | 115 } |
| 112 | 116 |
| 113 void WebLayerTreeViewImpl::DidCommitAndDrawFrame() { | 117 void WebLayerTreeViewImpl::DidCommitAndDrawFrame() { |
| (...skipping 134 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 248 base::Bind(&WebLayerTreeViewImpl::DidCreateSurfaceOnMainThread, | 252 base::Bind(&WebLayerTreeViewImpl::DidCreateSurfaceOnMainThread, |
| 249 main_thread_bound_weak_ptr_, | 253 main_thread_bound_weak_ptr_, |
| 250 id)); | 254 id)); |
| 251 } | 255 } |
| 252 | 256 |
| 253 void WebLayerTreeViewImpl::DidCreateSurfaceOnMainThread(cc::SurfaceId id) { | 257 void WebLayerTreeViewImpl::DidCreateSurfaceOnMainThread(cc::SurfaceId id) { |
| 254 view_->SetSurfaceId(SurfaceId::From(id)); | 258 view_->SetSurfaceId(SurfaceId::From(id)); |
| 255 } | 259 } |
| 256 | 260 |
| 257 } // namespace mojo | 261 } // namespace mojo |
| OLD | NEW |