Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(979)

Unified Diff: cc/tiles/picture_layer_tiling.h

Issue 2612413003: Clean up tile deletion (Closed)
Patch Set: "Fix Tile* comparison in tests" Created 3 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « cc/test/fake_tile_manager.cc ('k') | cc/tiles/picture_layer_tiling.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/tiles/picture_layer_tiling.h
diff --git a/cc/tiles/picture_layer_tiling.h b/cc/tiles/picture_layer_tiling.h
index 99e30d9f054c796c3a07999223931cfc26780c0a..45ad5ca6d358c014225096388bf48fd5c4442e44 100644
--- a/cc/tiles/picture_layer_tiling.h
+++ b/cc/tiles/picture_layer_tiling.h
@@ -39,7 +39,7 @@ class CC_EXPORT PictureLayerTilingClient {
public:
// Create a tile at the given content_rect (in the contents scale of the
// tiling) This might return null if the client cannot create such a tile.
- virtual ScopedTilePtr CreateTile(const Tile::CreateInfo& info) = 0;
+ virtual std::unique_ptr<Tile> CreateTile(const Tile::CreateInfo& info) = 0;
virtual gfx::Size CalculateTileSize(
const gfx::Size& content_bounds) const = 0;
// This invalidation region defines the area (if any, it can by null) that
@@ -268,12 +268,13 @@ class CC_EXPORT PictureLayerTiling {
EVENTUALLY_RECT
};
- using TileMap = std::unordered_map<TileMapKey, ScopedTilePtr, TileMapKeyHash>;
+ using TileMap =
+ std::unordered_map<TileMapKey, std::unique_ptr<Tile>, TileMapKeyHash>;
void SetLiveTilesRect(const gfx::Rect& live_tiles_rect);
void VerifyLiveTilesRect(bool is_on_recycle_tree) const;
Tile* CreateTile(const Tile::CreateInfo& info);
- ScopedTilePtr TakeTileAt(int i, int j);
+ std::unique_ptr<Tile> TakeTileAt(int i, int j);
// Returns true if the Tile existed and was removed from the tiling.
bool RemoveTileAt(int i, int j);
bool TilingMatchesTileIndices(const PictureLayerTiling* twin) const;
« no previous file with comments | « cc/test/fake_tile_manager.cc ('k') | cc/tiles/picture_layer_tiling.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698