summaryrefslogtreecommitdiffstats
path: root/cc/layers/picture_image_layer_impl.h
diff options
context:
space:
mode:
authorboliu@chromium.org <boliu@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2013-10-08 22:30:44 +0000
committerboliu@chromium.org <boliu@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2013-10-08 22:30:44 +0000
commitd4c07bf4b5f415352d7f27f67735559c39fbf3c6 (patch)
treee857e0c105f198e2117a50ba708b4b27d94edfbc /cc/layers/picture_image_layer_impl.h
parent5237280b6fdf52da1ef285a3fa0fed11be248fed (diff)
downloadchromium_src-d4c07bf4b5f415352d7f27f67735559c39fbf3c6.zip
chromium_src-d4c07bf4b5f415352d7f27f67735559c39fbf3c6.tar.gz
chromium_src-d4c07bf4b5f415352d7f27f67735559c39fbf3c6.tar.bz2
cc: Fix ideal_content_scale check in PictureImageLayerImpl
PictureImageLayerImpl ignores PictureLayerImpl::ideal_content_scale_ and conditionally sets tile scale to 1.f. This makes the comparison in PictureLayerImpl::AppendQuads to check for incomplete tiles incorrect. Fix by overriding PictureImageLayerImpl::CalculateContentsScale to always set ideal_content_scale_ to 1.f. Fix for internal bug b/9103603. TEST=PictureImageLayerImplTest.IgnoreIdealContentScale BUG= Review URL: https://codereview.chromium.org/26353002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@227614 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'cc/layers/picture_image_layer_impl.h')
-rw-r--r--cc/layers/picture_image_layer_impl.h9
1 files changed, 9 insertions, 0 deletions
diff --git a/cc/layers/picture_image_layer_impl.h b/cc/layers/picture_image_layer_impl.h
index 4a2db50..c475e53 100644
--- a/cc/layers/picture_image_layer_impl.h
+++ b/cc/layers/picture_image_layer_impl.h
@@ -17,9 +17,17 @@ class CC_EXPORT PictureImageLayerImpl : public PictureLayerImpl {
}
virtual ~PictureImageLayerImpl();
+ // LayerImpl overrides.
virtual const char* LayerTypeAsString() const OVERRIDE;
virtual scoped_ptr<LayerImpl> CreateLayerImpl(
LayerTreeImpl* tree_impl) OVERRIDE;
+ virtual void CalculateContentsScale(float ideal_contents_scale,
+ float device_scale_factor,
+ float page_scale_factor,
+ bool animating_transform_to_screen,
+ float* contents_scale_x,
+ float* contents_scale_y,
+ gfx::Size* content_bounds) OVERRIDE;
protected:
PictureImageLayerImpl(LayerTreeImpl* tree_impl, int id);
@@ -33,6 +41,7 @@ class CC_EXPORT PictureImageLayerImpl : public PictureLayerImpl {
virtual void GetDebugBorderProperties(
SkColor* color, float* width) const OVERRIDE;
+ private:
DISALLOW_COPY_AND_ASSIGN(PictureImageLayerImpl);
};