| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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 <stddef.h> | 5 #include <stddef.h> |
| 6 #include <stdint.h> | 6 #include <stdint.h> |
| 7 | 7 |
| 8 #include <utility> | 8 #include <utility> |
| 9 | 9 |
| 10 #include "base/bind.h" | 10 #include "base/bind.h" |
| (...skipping 1970 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1981 } | 1981 } |
| 1982 | 1982 |
| 1983 private: | 1983 private: |
| 1984 class FakeRasterBuffer : public RasterBuffer { | 1984 class FakeRasterBuffer : public RasterBuffer { |
| 1985 public: | 1985 public: |
| 1986 void Playback( | 1986 void Playback( |
| 1987 const RasterSource* raster_source, | 1987 const RasterSource* raster_source, |
| 1988 const gfx::Rect& raster_full_rect, | 1988 const gfx::Rect& raster_full_rect, |
| 1989 const gfx::Rect& raster_dirty_rect, | 1989 const gfx::Rect& raster_dirty_rect, |
| 1990 uint64_t new_content_id, | 1990 uint64_t new_content_id, |
| 1991 float scale, | 1991 const gfx::AxisTransform2d& transform, |
| 1992 const RasterSource::PlaybackSettings& playback_settings) override {} | 1992 const RasterSource::PlaybackSettings& playback_settings) override {} |
| 1993 }; | 1993 }; |
| 1994 }; | 1994 }; |
| 1995 | 1995 |
| 1996 class TileManagerReadyToDrawTest : public TileManagerTest { | 1996 class TileManagerReadyToDrawTest : public TileManagerTest { |
| 1997 public: | 1997 public: |
| 1998 ~TileManagerReadyToDrawTest() override { | 1998 ~TileManagerReadyToDrawTest() override { |
| 1999 // Ensure that the host impl doesn't outlive |raster_buffer_provider_|. | 1999 // Ensure that the host impl doesn't outlive |raster_buffer_provider_|. |
| 2000 TakeHostImpl(); | 2000 TakeHostImpl(); |
| 2001 } | 2001 } |
| (...skipping 375 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2377 // a part of raster tasks, the test should fail. | 2377 // a part of raster tasks, the test should fail. |
| 2378 host_impl()->tile_manager()->PrepareTiles(host_impl()->global_tile_state()); | 2378 host_impl()->tile_manager()->PrepareTiles(host_impl()->global_tile_state()); |
| 2379 EXPECT_TRUE(host_impl()->tile_manager()->HasScheduledTileTasksForTesting()); | 2379 EXPECT_TRUE(host_impl()->tile_manager()->HasScheduledTileTasksForTesting()); |
| 2380 static_cast<SynchronousTaskGraphRunner*>(task_graph_runner())->RunUntilIdle(); | 2380 static_cast<SynchronousTaskGraphRunner*>(task_graph_runner())->RunUntilIdle(); |
| 2381 base::RunLoop().RunUntilIdle(); | 2381 base::RunLoop().RunUntilIdle(); |
| 2382 EXPECT_FALSE(host_impl()->tile_manager()->HasScheduledTileTasksForTesting()); | 2382 EXPECT_FALSE(host_impl()->tile_manager()->HasScheduledTileTasksForTesting()); |
| 2383 } | 2383 } |
| 2384 | 2384 |
| 2385 } // namespace | 2385 } // namespace |
| 2386 } // namespace cc | 2386 } // namespace cc |
| OLD | NEW |