| 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 <algorithm> | 7 #include <algorithm> |
| 8 #include <cmath> | 8 #include <cmath> |
| 9 | 9 |
| 10 #include "base/bind.h" | 10 #include "base/bind.h" |
| (...skipping 142 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 153 void PostDelayedAnimationTaskOnImplThread(const base::Closure& task, | 153 void PostDelayedAnimationTaskOnImplThread(const base::Closure& task, |
| 154 base::TimeDelta delay) override { | 154 base::TimeDelta delay) override { |
| 155 animation_task_ = task; | 155 animation_task_ = task; |
| 156 requested_animation_delay_ = delay; | 156 requested_animation_delay_ = delay; |
| 157 } | 157 } |
| 158 void DidActivateSyncTree() override {} | 158 void DidActivateSyncTree() override {} |
| 159 void DidPrepareTiles() override {} | 159 void DidPrepareTiles() override {} |
| 160 void DidCompletePageScaleAnimationOnImplThread() override { | 160 void DidCompletePageScaleAnimationOnImplThread() override { |
| 161 did_complete_page_scale_animation_ = true; | 161 did_complete_page_scale_animation_ = true; |
| 162 } | 162 } |
| 163 base::TimeTicks GetNextPredictedRequestAnimationFrameTime() const override { |
| 164 NOTREACHED(); |
| 165 return base::TimeTicks(); |
| 166 } |
| 163 | 167 |
| 164 void set_reduce_memory_result(bool reduce_memory_result) { | 168 void set_reduce_memory_result(bool reduce_memory_result) { |
| 165 reduce_memory_result_ = reduce_memory_result; | 169 reduce_memory_result_ = reduce_memory_result; |
| 166 } | 170 } |
| 167 | 171 |
| 168 virtual bool CreateHostImpl(const LayerTreeSettings& settings, | 172 virtual bool CreateHostImpl(const LayerTreeSettings& settings, |
| 169 scoped_ptr<OutputSurface> output_surface) { | 173 scoped_ptr<OutputSurface> output_surface) { |
| 170 host_impl_ = LayerTreeHostImpl::Create(settings, | 174 host_impl_ = LayerTreeHostImpl::Create(settings, |
| 171 this, | 175 this, |
| 172 &proxy_, | 176 &proxy_, |
| (...skipping 8326 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 8499 // surface. | 8503 // surface. |
| 8500 EXPECT_EQ(0, num_lost_surfaces_); | 8504 EXPECT_EQ(0, num_lost_surfaces_); |
| 8501 host_impl_->DidLoseOutputSurface(); | 8505 host_impl_->DidLoseOutputSurface(); |
| 8502 EXPECT_EQ(1, num_lost_surfaces_); | 8506 EXPECT_EQ(1, num_lost_surfaces_); |
| 8503 host_impl_->DidLoseOutputSurface(); | 8507 host_impl_->DidLoseOutputSurface(); |
| 8504 EXPECT_LE(1, num_lost_surfaces_); | 8508 EXPECT_LE(1, num_lost_surfaces_); |
| 8505 } | 8509 } |
| 8506 | 8510 |
| 8507 } // namespace | 8511 } // namespace |
| 8508 } // namespace cc | 8512 } // namespace cc |
| OLD | NEW |