| OLD | NEW |
| 1 // Copyright 2010 The Chromium Authors. All rights reserved. | 1 // Copyright 2010 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "cc/layer.h" | 5 #include "cc/layer.h" |
| 6 | 6 |
| 7 #include "cc/animation.h" | 7 #include "cc/animation.h" |
| 8 #include "cc/animation_events.h" | 8 #include "cc/animation_events.h" |
| 9 #include "cc/layer_animation_controller.h" | 9 #include "cc/layer_animation_controller.h" |
| 10 #include "cc/layer_impl.h" | 10 #include "cc/layer_impl.h" |
| (...skipping 378 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 389 if (opacity_ == opacity) | 389 if (opacity_ == opacity) |
| 390 return; | 390 return; |
| 391 opacity_ = opacity; | 391 opacity_ = opacity; |
| 392 SetNeedsCommit(); | 392 SetNeedsCommit(); |
| 393 } | 393 } |
| 394 | 394 |
| 395 bool Layer::OpacityIsAnimating() const { | 395 bool Layer::OpacityIsAnimating() const { |
| 396 return layer_animation_controller_->IsAnimatingProperty(Animation::Opacity); | 396 return layer_animation_controller_->IsAnimatingProperty(Animation::Opacity); |
| 397 } | 397 } |
| 398 | 398 |
| 399 bool Layer::DoNotSkipOnZeroOpacity() const { |
| 400 return false; |
| 401 } |
| 402 |
| 399 void Layer::SetContentsOpaque(bool opaque) { | 403 void Layer::SetContentsOpaque(bool opaque) { |
| 400 if (contents_opaque_ == opaque) | 404 if (contents_opaque_ == opaque) |
| 401 return; | 405 return; |
| 402 contents_opaque_ = opaque; | 406 contents_opaque_ = opaque; |
| 403 SetNeedsCommit(); | 407 SetNeedsCommit(); |
| 404 } | 408 } |
| 405 | 409 |
| 406 void Layer::SetPosition(gfx::PointF position) { | 410 void Layer::SetPosition(gfx::PointF position) { |
| 407 if (position_ == position) | 411 if (position_ == position) |
| 408 return; | 412 return; |
| (...skipping 393 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 802 if (contents_opaque()) | 806 if (contents_opaque()) |
| 803 return visible_content_rect(); | 807 return visible_content_rect(); |
| 804 return Region(); | 808 return Region(); |
| 805 } | 809 } |
| 806 | 810 |
| 807 ScrollbarLayer* Layer::ToScrollbarLayer() { | 811 ScrollbarLayer* Layer::ToScrollbarLayer() { |
| 808 return NULL; | 812 return NULL; |
| 809 } | 813 } |
| 810 | 814 |
| 811 } // namespace cc | 815 } // namespace cc |
| OLD | NEW |