Chromium Code Reviews| Index: ui/compositor/layer.cc |
| diff --git a/ui/compositor/layer.cc b/ui/compositor/layer.cc |
| index 7c43b7b84d030900fdf7bd7c869de1b18e4cad4c..15dc5c6b83386f2f4a7c2edad6818527234d1887 100644 |
| --- a/ui/compositor/layer.cc |
| +++ b/ui/compositor/layer.cc |
| @@ -791,12 +791,11 @@ void Layer::RecomputeDrawsContentAndUVRect() { |
| gfx::Size size(std::min(bounds().width(), texture_size.width()), |
| std::min(bounds().height(), texture_size.height())); |
| - gfx::RectF rect( |
| - 0, |
| - 0, |
| + gfx::PointF uv_top_left(0, 0); |
|
danakj
2013/01/15 01:48:42
nit: 0.f
Jerome
2013/01/15 17:58:12
Done.
|
| + gfx::PointF uv_bottom_right( |
| static_cast<float>(size.width())/texture_size.width(), |
| static_cast<float>(size.height())/texture_size.height()); |
| - texture_layer_->setUVRect(rect); |
| + texture_layer_->setUV(uv_top_left, uv_bottom_right); |
| cc_layer_->setBounds(ConvertSizeToPixel(this, size)); |
| } |