| 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 #ifndef CC_RESOURCES_TILE_MANAGER_H_ | 5 #ifndef CC_RESOURCES_TILE_MANAGER_H_ |
| 6 #define CC_RESOURCES_TILE_MANAGER_H_ | 6 #define CC_RESOURCES_TILE_MANAGER_H_ |
| 7 | 7 |
| 8 #include <deque> | 8 #include <deque> |
| 9 #include <queue> | 9 #include <queue> |
| 10 #include <set> | 10 #include <set> |
| (...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 53 // Called when the visible representation of a tile might have changed. Some | 53 // Called when the visible representation of a tile might have changed. Some |
| 54 // examples are: | 54 // examples are: |
| 55 // - Tile version initialized. | 55 // - Tile version initialized. |
| 56 // - Tile resources freed. | 56 // - Tile resources freed. |
| 57 // - Tile marked for on-demand raster. | 57 // - Tile marked for on-demand raster. |
| 58 virtual void NotifyTileStateChanged(const Tile* tile) = 0; | 58 virtual void NotifyTileStateChanged(const Tile* tile) = 0; |
| 59 | 59 |
| 60 // Given an empty raster tile priority queue, this will build a priority queue | 60 // Given an empty raster tile priority queue, this will build a priority queue |
| 61 // that will return tiles in order in which they should be rasterized. | 61 // that will return tiles in order in which they should be rasterized. |
| 62 // Note if the queue was previous built, Reset must be called on it. | 62 // Note if the queue was previous built, Reset must be called on it. |
| 63 virtual void BuildRasterQueue(RasterTilePriorityQueue* queue, | 63 virtual scoped_ptr<RasterTilePriorityQueue> BuildRasterQueue( |
| 64 TreePriority tree_priority, | 64 TreePriority tree_priority, |
| 65 RasterTilePriorityQueue::Type type) = 0; | 65 RasterTilePriorityQueue::Type type) = 0; |
| 66 | 66 |
| 67 // Given an empty eviction tile priority queue, this will build a priority | 67 // Given an empty eviction tile priority queue, this will build a priority |
| 68 // queue that will return tiles in order in which they should be evicted. | 68 // queue that will return tiles in order in which they should be evicted. |
| 69 // Note if the queue was previous built, Reset must be called on it. | 69 // Note if the queue was previous built, Reset must be called on it. |
| 70 // TODO(vmpstr): Change this to scoped_ptr<EvictionQueue> Build... |
| 70 virtual void BuildEvictionQueue(EvictionTilePriorityQueue* queue, | 71 virtual void BuildEvictionQueue(EvictionTilePriorityQueue* queue, |
| 71 TreePriority tree_priority) = 0; | 72 TreePriority tree_priority) = 0; |
| 72 | 73 |
| 73 protected: | 74 protected: |
| 74 virtual ~TileManagerClient() {} | 75 virtual ~TileManagerClient() {} |
| 75 }; | 76 }; |
| 76 | 77 |
| 77 struct RasterTaskCompletionStats { | 78 struct RasterTaskCompletionStats { |
| 78 RasterTaskCompletionStats(); | 79 RasterTaskCompletionStats(); |
| 79 | 80 |
| (...skipping 230 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 310 | 311 |
| 311 bool did_notify_ready_to_activate_; | 312 bool did_notify_ready_to_activate_; |
| 312 bool did_notify_ready_to_draw_; | 313 bool did_notify_ready_to_draw_; |
| 313 | 314 |
| 314 DISALLOW_COPY_AND_ASSIGN(TileManager); | 315 DISALLOW_COPY_AND_ASSIGN(TileManager); |
| 315 }; | 316 }; |
| 316 | 317 |
| 317 } // namespace cc | 318 } // namespace cc |
| 318 | 319 |
| 319 #endif // CC_RESOURCES_TILE_MANAGER_H_ | 320 #endif // CC_RESOURCES_TILE_MANAGER_H_ |
| OLD | NEW |