| Index: cc/picture_layer_tiling.h
|
| diff --git a/cc/picture_layer_tiling.h b/cc/picture_layer_tiling.h
|
| index bf504b8386ba13362a05668c8d45143f5feee3db..bd1c21af9b1cfc5a9fc547a16e5a192a4b941335 100644
|
| --- a/cc/picture_layer_tiling.h
|
| +++ b/cc/picture_layer_tiling.h
|
| @@ -19,6 +19,7 @@
|
| namespace cc {
|
|
|
| class PictureLayerTiling;
|
| +class ManagedTileState;
|
|
|
| class PictureLayerTilingClient {
|
| public:
|
| @@ -33,6 +34,16 @@ class PictureLayerTilingClient {
|
| gfx::Size content_bounds) = 0;
|
| };
|
|
|
| +class TileHandle {
|
| + public:
|
| + TileHandle(scoped_refptr<Tile> tile);
|
| + ~TileHandle();
|
| + Tile* tile() const { return tile_.get(); }
|
| + private:
|
| + scoped_refptr<Tile> tile_;
|
| + scoped_refptr<ManagedTileState> managed_tile_state_;
|
| +};
|
| +
|
| class CC_EXPORT PictureLayerTiling {
|
| public:
|
| ~PictureLayerTiling();
|
| @@ -61,7 +72,7 @@ class CC_EXPORT PictureLayerTiling {
|
| std::vector<Tile*> all_tiles;
|
| for (TileMap::const_iterator it = tiles_.begin();
|
| it != tiles_.end(); ++it)
|
| - all_tiles.push_back(it->second);
|
| + all_tiles.push_back(it->second.tile());
|
| return all_tiles;
|
| }
|
|
|
| @@ -148,7 +159,7 @@ class CC_EXPORT PictureLayerTiling {
|
|
|
| protected:
|
| typedef std::pair<int, int> TileMapKey;
|
| - typedef base::hash_map<TileMapKey, scoped_refptr<Tile> > TileMap;
|
| + typedef base::hash_map<TileMapKey, TileHandle> TileMap;
|
|
|
| PictureLayerTiling(float contents_scale);
|
| Tile* TileAt(int, int) const;
|
|
|