diff options
author | vmpstr <vmpstr@chromium.org> | 2014-08-26 11:51:52 -0700 |
---|---|---|
committer | Commit bot <commit-bot@chromium.org> | 2014-08-26 18:59:35 +0000 |
commit | 7fceb77977afd9af22215eb9cd28ab667567668e (patch) | |
tree | aa487b33e9a6b81dd5d2c5c2b0287eef5bf4278e /cc/test/fake_picture_layer_tiling_client.h | |
parent | aa7e9b61d69dfa8e0a1557d900037bfb8b1e6e78 (diff) | |
download | chromium_src-7fceb77977afd9af22215eb9cd28ab667567668e.zip chromium_src-7fceb77977afd9af22215eb9cd28ab667567668e.tar.gz chromium_src-7fceb77977afd9af22215eb9cd28ab667567668e.tar.bz2 |
cc: Remove tiles from recycle tree that were deleted on active.
This patch removes tiles from the recycle tree that were deleted from
the active tree as a result of a shifting live tiles rect. It is
important to do this, since if the active tree then would recreate
the deleted tile (ie, live tiles rect shift back), we have to ensure
that this tile will be shared when the next pending tree is created.
If we don't do it, we can run into a situation in which we will
continuously raster the same tile.
The patch does the following:
- Adds a way to get a recycled tree twin tiling.
- During LiveTilesRect tile deletion, deletes tiles from the same
location from the recycle twin (if one exists).
R=danakj, enne
Review URL: https://codereview.chromium.org/502453003
Cr-Commit-Position: refs/heads/master@{#291949}
Diffstat (limited to 'cc/test/fake_picture_layer_tiling_client.h')
-rw-r--r-- | cc/test/fake_picture_layer_tiling_client.h | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/cc/test/fake_picture_layer_tiling_client.h b/cc/test/fake_picture_layer_tiling_client.h index f46cc84..edd2a61 100644 --- a/cc/test/fake_picture_layer_tiling_client.h +++ b/cc/test/fake_picture_layer_tiling_client.h @@ -36,9 +36,14 @@ class FakePictureLayerTilingClient : public PictureLayerTilingClient { virtual const Region* GetInvalidation() OVERRIDE; virtual const PictureLayerTiling* GetTwinTiling( const PictureLayerTiling* tiling) const OVERRIDE; + virtual PictureLayerTiling* GetRecycledTwinTiling( + const PictureLayerTiling* tiling) OVERRIDE; virtual WhichTree GetTree() const OVERRIDE; void set_twin_tiling(PictureLayerTiling* tiling) { twin_tiling_ = tiling; } + void set_recycled_twin_tiling(PictureLayerTiling* tiling) { + recycled_twin_tiling_ = tiling; + } void set_text_rect(const gfx::Rect& rect) { text_rect_ = rect; } void set_allow_create_tile(bool allow) { allow_create_tile_ = allow; } void set_invalidation(const Region& region) { invalidation_ = region; } @@ -64,6 +69,7 @@ class FakePictureLayerTilingClient : public PictureLayerTilingClient { scoped_refptr<PicturePileImpl> pile_; gfx::Size tile_size_; PictureLayerTiling* twin_tiling_; + PictureLayerTiling* recycled_twin_tiling_; gfx::Rect text_rect_; bool allow_create_tile_; Region invalidation_; |