| OLD | NEW |
| 1 // Copyright 2011 The Chromium Authors. All rights reserved. | 1 // Copyright 2011 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 "cc/trees/layer_tree_host_impl.h" | 5 #include "cc/trees/layer_tree_host_impl.h" |
| 6 | 6 |
| 7 #include <stddef.h> | 7 #include <stddef.h> |
| 8 #include <stdint.h> | 8 #include <stdint.h> |
| 9 | 9 |
| 10 #include <algorithm> | 10 #include <algorithm> |
| (...skipping 1811 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1822 void LayerTreeHostImpl::WillBeginImplFrame(const BeginFrameArgs& args) { | 1822 void LayerTreeHostImpl::WillBeginImplFrame(const BeginFrameArgs& args) { |
| 1823 current_begin_frame_tracker_.Start(args); | 1823 current_begin_frame_tracker_.Start(args); |
| 1824 | 1824 |
| 1825 if (is_likely_to_require_a_draw_) { | 1825 if (is_likely_to_require_a_draw_) { |
| 1826 // Optimistically schedule a draw. This will let us expect the tile manager | 1826 // Optimistically schedule a draw. This will let us expect the tile manager |
| 1827 // to complete its work so that we can draw new tiles within the impl frame | 1827 // to complete its work so that we can draw new tiles within the impl frame |
| 1828 // we are beginning now. | 1828 // we are beginning now. |
| 1829 SetNeedsRedraw(); | 1829 SetNeedsRedraw(); |
| 1830 } | 1830 } |
| 1831 | 1831 |
| 1832 if (input_handler_client_) |
| 1833 input_handler_client_->DeliverInputForBeginFrame(); |
| 1834 |
| 1832 Animate(); | 1835 Animate(); |
| 1833 | 1836 |
| 1834 for (auto* it : video_frame_controllers_) | 1837 for (auto* it : video_frame_controllers_) |
| 1835 it->OnBeginFrame(args); | 1838 it->OnBeginFrame(args); |
| 1836 } | 1839 } |
| 1837 | 1840 |
| 1838 void LayerTreeHostImpl::DidFinishImplFrame() { | 1841 void LayerTreeHostImpl::DidFinishImplFrame() { |
| 1839 current_begin_frame_tracker_.Finish(); | 1842 current_begin_frame_tracker_.Finish(); |
| 1840 } | 1843 } |
| 1841 | 1844 |
| (...skipping 2233 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 4075 worker_context_visibility_ = | 4078 worker_context_visibility_ = |
| 4076 worker_context->CacheController()->ClientBecameVisible(); | 4079 worker_context->CacheController()->ClientBecameVisible(); |
| 4077 } else { | 4080 } else { |
| 4078 worker_context->CacheController()->ClientBecameNotVisible( | 4081 worker_context->CacheController()->ClientBecameNotVisible( |
| 4079 std::move(worker_context_visibility_)); | 4082 std::move(worker_context_visibility_)); |
| 4080 } | 4083 } |
| 4081 } | 4084 } |
| 4082 } | 4085 } |
| 4083 | 4086 |
| 4084 } // namespace cc | 4087 } // namespace cc |
| OLD | NEW |