Upstream version 5.34.104.0
[platform/framework/web/crosswalk.git] / src / webkit / renderer / compositor_bindings / web_layer_impl_fixed_bounds.cc
index 793390e..ec6d743 100644 (file)
@@ -24,41 +24,31 @@ WebLayerImplFixedBounds::WebLayerImplFixedBounds(scoped_refptr<Layer> layer)
 WebLayerImplFixedBounds::~WebLayerImplFixedBounds() {
 }
 
-void WebLayerImplFixedBounds::invalidateRect(const WebKit::WebFloatRect& rect) {
+void WebLayerImplFixedBounds::invalidateRect(const blink::WebFloatRect& rect) {
   // Partial invalidations seldom occur for such layers.
   // Simply invalidate the whole layer to avoid transformation of coordinates.
   invalidate();
 }
 
 void WebLayerImplFixedBounds::setAnchorPoint(
-    const WebKit::WebFloatPoint& anchor_point) {
+    const blink::WebFloatPoint& anchor_point) {
   if (anchor_point != this->anchorPoint()) {
     layer_->SetAnchorPoint(anchor_point);
     UpdateLayerBoundsAndTransform();
   }
 }
 
-void WebLayerImplFixedBounds::setBounds(const WebKit::WebSize& bounds) {
+void WebLayerImplFixedBounds::setBounds(const blink::WebSize& bounds) {
   if (original_bounds_ != gfx::Size(bounds)) {
       original_bounds_ = bounds;
       UpdateLayerBoundsAndTransform();
   }
 }
 
-WebKit::WebSize WebLayerImplFixedBounds::bounds() const {
+blink::WebSize WebLayerImplFixedBounds::bounds() const {
   return original_bounds_;
 }
 
-void WebLayerImplFixedBounds::setSublayerTransform(const SkMatrix44& matrix) {
-  gfx::Transform transform;
-  transform.matrix() = matrix;
-  SetSublayerTransformInternal(transform);
-}
-
-SkMatrix44 WebLayerImplFixedBounds::sublayerTransform() const {
-  return original_sublayer_transform_.matrix();
-}
-
 void WebLayerImplFixedBounds::setTransform(const SkMatrix44& matrix) {
   gfx::Transform transform;
   transform.matrix() = matrix;
@@ -76,14 +66,6 @@ void WebLayerImplFixedBounds::SetFixedBounds(gfx::Size fixed_bounds) {
   }
 }
 
-void WebLayerImplFixedBounds::SetSublayerTransformInternal(
-    const gfx::Transform& transform) {
-  if (original_sublayer_transform_ != transform) {
-    original_sublayer_transform_ = transform;
-    UpdateLayerBoundsAndTransform();
-  }
-}
-
 void WebLayerImplFixedBounds::SetTransformInternal(
     const gfx::Transform& transform) {
   if (original_transform_ != transform) {
@@ -100,7 +82,6 @@ void WebLayerImplFixedBounds::UpdateLayerBoundsAndTransform() {
       anchorPoint().x || anchorPoint().y) {
     layer_->SetBounds(original_bounds_);
     layer_->SetTransform(original_transform_);
-    layer_->SetSublayerTransform(original_sublayer_transform_);
     return;
   }
 
@@ -114,15 +95,6 @@ void WebLayerImplFixedBounds::UpdateLayerBoundsAndTransform() {
       static_cast<float>(original_bounds_.height()) / fixed_bounds_.height();
   transform_with_bounds_scale.Scale(bounds_scale_x, bounds_scale_y);
   layer_->SetTransform(transform_with_bounds_scale);
-
-  // As we apply extra scale transform on this layer which will propagate to the
-  // sublayers, here undo the scale on sublayers.
-  gfx::Transform sublayer_transform_with_inverse_bounds_scale;
-  sublayer_transform_with_inverse_bounds_scale.Scale(1.f / bounds_scale_x,
-                                                     1.f / bounds_scale_y);
-  sublayer_transform_with_inverse_bounds_scale.PreconcatTransform(
-      original_sublayer_transform_);
-  layer_->SetSublayerTransform(sublayer_transform_with_inverse_bounds_scale);
 }
 
-}  // namespace WebKit
+}  // namespace webkit