OLD | NEW |
1 // Copyright 2012 The Chromium Authors. All rights reserved. | 1 // Copyright 2012 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/layers/layer_impl.h" | 5 #include "cc/layers/layer_impl.h" |
6 | 6 |
7 #include <stddef.h> | 7 #include <stddef.h> |
8 #include <stdint.h> | 8 #include <stdint.h> |
9 | 9 |
10 #include <utility> | 10 #include <utility> |
(...skipping 446 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
457 | 457 |
458 void LayerImpl::set_user_scrollable_vertical(bool scrollable) { | 458 void LayerImpl::set_user_scrollable_vertical(bool scrollable) { |
459 user_scrollable_vertical_ = scrollable; | 459 user_scrollable_vertical_ = scrollable; |
460 } | 460 } |
461 | 461 |
462 bool LayerImpl::user_scrollable(ScrollbarOrientation orientation) const { | 462 bool LayerImpl::user_scrollable(ScrollbarOrientation orientation) const { |
463 return (orientation == HORIZONTAL) ? user_scrollable_horizontal_ | 463 return (orientation == HORIZONTAL) ? user_scrollable_horizontal_ |
464 : user_scrollable_vertical_; | 464 : user_scrollable_vertical_; |
465 } | 465 } |
466 | 466 |
467 skia::RefPtr<SkPicture> LayerImpl::GetPicture() { | 467 sk_sp<SkPicture> LayerImpl::GetPicture() { |
468 return skia::RefPtr<SkPicture>(); | 468 return nullptr; |
469 } | 469 } |
470 | 470 |
471 scoped_ptr<LayerImpl> LayerImpl::CreateLayerImpl(LayerTreeImpl* tree_impl) { | 471 scoped_ptr<LayerImpl> LayerImpl::CreateLayerImpl(LayerTreeImpl* tree_impl) { |
472 return LayerImpl::Create(tree_impl, layer_id_); | 472 return LayerImpl::Create(tree_impl, layer_id_); |
473 } | 473 } |
474 | 474 |
475 void LayerImpl::set_main_thread_scrolling_reasons( | 475 void LayerImpl::set_main_thread_scrolling_reasons( |
476 uint32_t main_thread_scrolling_reasons) { | 476 uint32_t main_thread_scrolling_reasons) { |
477 if (main_thread_scrolling_reasons_ == main_thread_scrolling_reasons) | 477 if (main_thread_scrolling_reasons_ == main_thread_scrolling_reasons) |
478 return; | 478 return; |
(...skipping 1101 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1580 .layer_transforms_should_scale_layer_contents) { | 1580 .layer_transforms_should_scale_layer_contents) { |
1581 return default_scale; | 1581 return default_scale; |
1582 } | 1582 } |
1583 | 1583 |
1584 gfx::Vector2dF transform_scales = MathUtil::ComputeTransform2dScaleComponents( | 1584 gfx::Vector2dF transform_scales = MathUtil::ComputeTransform2dScaleComponents( |
1585 DrawTransform(), default_scale); | 1585 DrawTransform(), default_scale); |
1586 return std::max(transform_scales.x(), transform_scales.y()); | 1586 return std::max(transform_scales.x(), transform_scales.y()); |
1587 } | 1587 } |
1588 | 1588 |
1589 } // namespace cc | 1589 } // namespace cc |
OLD | NEW |