diff options
author | enne@chromium.org <enne@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2013-02-27 02:03:04 +0000 |
---|---|---|
committer | enne@chromium.org <enne@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2013-02-27 02:03:04 +0000 |
commit | b06a972dc4a388f18591bdbdd7a731690d7a08ef (patch) | |
tree | 3310bb77a876dd870a256dac49aa794bcbc17944 /cc/test/fake_picture_layer_tiling_client.cc | |
parent | 8467ae0d1f638f071515b3759d448c878b63ba5f (diff) | |
download | chromium_src-b06a972dc4a388f18591bdbdd7a731690d7a08ef.zip chromium_src-b06a972dc4a388f18591bdbdd7a731690d7a08ef.tar.gz chromium_src-b06a972dc4a388f18591bdbdd7a731690d7a08ef.tar.bz2 |
cc: DCHECK that tiles are rasterizable
This is a follow-up refactoring to r184525 that adds additional DCHECKS around
tiles being rasterizable whenever their picture pile is set or changed.
R=danakj@chromium.org
BUG=177823
Review URL: https://chromiumcodereview.appspot.com/12321126
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@184830 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'cc/test/fake_picture_layer_tiling_client.cc')
-rw-r--r-- | cc/test/fake_picture_layer_tiling_client.cc | 16 |
1 files changed, 15 insertions, 1 deletions
diff --git a/cc/test/fake_picture_layer_tiling_client.cc b/cc/test/fake_picture_layer_tiling_client.cc index 2fa3de8..129f965 100644 --- a/cc/test/fake_picture_layer_tiling_client.cc +++ b/cc/test/fake_picture_layer_tiling_client.cc @@ -6,9 +6,23 @@ namespace cc { +class FakeInfinitePicturePileImpl : public PicturePileImpl +{ + public: + FakeInfinitePicturePileImpl() { + gfx::Size size(std::numeric_limits<int>::max(), + std::numeric_limits<int>::max()); + Resize(size); + recorded_region_ = Region(gfx::Rect(size)); + } + + protected: + ~FakeInfinitePicturePileImpl() {} +}; + FakePictureLayerTilingClient::FakePictureLayerTilingClient() : tile_manager_(&tile_manager_client_, NULL, 1, false), - pile_(PicturePileImpl::Create()) { + pile_(new FakeInfinitePicturePileImpl()) { } FakePictureLayerTilingClient::~FakePictureLayerTilingClient() { |