| OLD | NEW |
| 1 // Copyright 2012 The Chromium Authors. All rights reserved. | 1 // Copyright 2012 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/layer_tree_host.h" | 5 #include "cc/layer_tree_host.h" |
| 6 | 6 |
| 7 #include "cc/animation_curve.h" | 7 #include "cc/animation_curve.h" |
| 8 #include "cc/layer.h" | 8 #include "cc/layer.h" |
| 9 #include "cc/layer_animation_controller.h" | 9 #include "cc/layer_animation_controller.h" |
| 10 #include "cc/layer_impl.h" | 10 #include "cc/layer_impl.h" |
| (...skipping 363 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 374 | 374 |
| 375 virtual void beginTest() OVERRIDE { | 375 virtual void beginTest() OVERRIDE { |
| 376 postAddAnimationToMainThread(update_check_layer_.get()); | 376 postAddAnimationToMainThread(update_check_layer_.get()); |
| 377 } | 377 } |
| 378 | 378 |
| 379 virtual void commitCompleteOnThread(LayerTreeHostImpl*) OVERRIDE { | 379 virtual void commitCompleteOnThread(LayerTreeHostImpl*) OVERRIDE { |
| 380 endTest(); | 380 endTest(); |
| 381 } | 381 } |
| 382 | 382 |
| 383 virtual void afterTest() OVERRIDE { | 383 virtual void afterTest() OVERRIDE { |
| 384 // update() should have been called once, proving that the layer was not | 384 // update() should have been called, proving that the layer was not |
| 385 // skipped. | 385 // skipped. |
| 386 EXPECT_EQ(1, update_check_layer_->update_count()); | 386 EXPECT_NE(0, update_check_layer_->update_count()); |
| 387 | 387 |
| 388 // clear update_check_layer_ so LayerTreeHost dies. | 388 // clear update_check_layer_ so LayerTreeHost dies. |
| 389 update_check_layer_ = NULL; | 389 update_check_layer_ = NULL; |
| 390 } | 390 } |
| 391 | 391 |
| 392 private: | 392 private: |
| 393 FakeContentLayerClient client_; | 393 FakeContentLayerClient client_; |
| 394 scoped_refptr<FakeContentLayer> update_check_layer_; | 394 scoped_refptr<FakeContentLayer> update_check_layer_; |
| 395 }; | 395 }; |
| 396 | 396 |
| (...skipping 131 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 528 | 528 |
| 529 private: | 529 private: |
| 530 int num_commit_complete_; | 530 int num_commit_complete_; |
| 531 int num_draw_layers_; | 531 int num_draw_layers_; |
| 532 }; | 532 }; |
| 533 | 533 |
| 534 MULTI_THREAD_TEST_F(LayerTreeHostAnimationTestContinuousAnimate) | 534 MULTI_THREAD_TEST_F(LayerTreeHostAnimationTestContinuousAnimate) |
| 535 | 535 |
| 536 } // namespace | 536 } // namespace |
| 537 } // namespace cc | 537 } // namespace cc |
| OLD | NEW |