| Index: cc/layer.cc
|
| diff --git a/cc/layer.cc b/cc/layer.cc
|
| index f3f9b4d0dab6c04adf7c6b032164eab4eb0c00ce..dd410defd952f4590d8e28574766dc89586d6d18 100644
|
| --- a/cc/layer.cc
|
| +++ b/cc/layer.cc
|
| @@ -222,12 +222,19 @@ void Layer::setBounds(const gfx::Size& size)
|
|
|
| m_bounds = size;
|
|
|
| + didUpdateBounds();
|
| +
|
| if (firstResize)
|
| setNeedsDisplay();
|
| else
|
| setNeedsCommit();
|
| }
|
|
|
| +void Layer::didUpdateBounds()
|
| +{
|
| + m_drawProperties.content_bounds = bounds();
|
| +}
|
| +
|
| Layer* Layer::rootLayer()
|
| {
|
| Layer* layer = this;
|
| @@ -280,9 +287,12 @@ void Layer::setBackgroundColor(SkColor backgroundColor)
|
| setNeedsCommit();
|
| }
|
|
|
| -gfx::Size Layer::contentBounds() const
|
| +void Layer::setIdealContentsScale(float ideal_contents_scale)
|
| {
|
| - return bounds();
|
| + m_drawProperties.ideal_contents_scale = ideal_contents_scale;
|
| + m_drawProperties.contents_scale_x = 1;
|
| + m_drawProperties.contents_scale_y = 1;
|
| + m_drawProperties.content_bounds = bounds();
|
| }
|
|
|
| void Layer::setMasksToBounds(bool masksToBounds)
|
| @@ -640,16 +650,6 @@ void Layer::setDebugName(const std::string& debugName)
|
| setNeedsCommit();
|
| }
|
|
|
| -float Layer::contentsScaleX() const
|
| -{
|
| - return 1.0;
|
| -}
|
| -
|
| -float Layer::contentsScaleY() const
|
| -{
|
| - return 1.0;
|
| -}
|
| -
|
| void Layer::setRasterScale(float scale)
|
| {
|
| if (m_rasterScale == scale)
|
|
|