Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(58)

Side by Side Diff: cc/layers/layer_impl.cc

Issue 2349713002: [cc] Remove unused parameter to DidUpdateScrollOffset (Closed)
Patch Set: address reviewer comments. Created 4 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | cc/layers/layer_impl_unittest.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 <algorithm> 10 #include <algorithm>
(...skipping 812 matching lines...) Expand 10 before | Expand all | Expand 10 after
823 } 823 }
824 824
825 void LayerImpl::AddDamageRect(const gfx::Rect& damage_rect) { 825 void LayerImpl::AddDamageRect(const gfx::Rect& damage_rect) {
826 damage_rect_.Union(damage_rect); 826 damage_rect_.Union(damage_rect);
827 } 827 }
828 828
829 void LayerImpl::SetCurrentScrollOffset(const gfx::ScrollOffset& scroll_offset) { 829 void LayerImpl::SetCurrentScrollOffset(const gfx::ScrollOffset& scroll_offset) {
830 DCHECK(IsActive()); 830 DCHECK(IsActive());
831 if (layer_tree_impl()->property_trees()->scroll_tree.SetScrollOffset( 831 if (layer_tree_impl()->property_trees()->scroll_tree.SetScrollOffset(
832 id(), scroll_offset)) 832 id(), scroll_offset))
833 layer_tree_impl()->DidUpdateScrollOffset(id(), transform_tree_index()); 833 layer_tree_impl()->DidUpdateScrollOffset(id());
834 } 834 }
835 835
836 gfx::ScrollOffset LayerImpl::CurrentScrollOffset() const { 836 gfx::ScrollOffset LayerImpl::CurrentScrollOffset() const {
837 return layer_tree_impl()->property_trees()->scroll_tree.current_scroll_offset( 837 return layer_tree_impl()->property_trees()->scroll_tree.current_scroll_offset(
838 id()); 838 id());
839 } 839 }
840 840
841 void LayerImpl::UpdatePropertyTreeScrollOffset() { 841 void LayerImpl::UpdatePropertyTreeScrollOffset() {
842 // TODO(enne): in the future, scrolling should update the scroll tree 842 // TODO(enne): in the future, scrolling should update the scroll tree
843 // directly instead of going through layers. 843 // directly instead of going through layers.
(...skipping 263 matching lines...) Expand 10 before | Expand all | Expand 10 after
1107 .layer_transforms_should_scale_layer_contents) { 1107 .layer_transforms_should_scale_layer_contents) {
1108 return default_scale; 1108 return default_scale;
1109 } 1109 }
1110 1110
1111 gfx::Vector2dF transform_scales = MathUtil::ComputeTransform2dScaleComponents( 1111 gfx::Vector2dF transform_scales = MathUtil::ComputeTransform2dScaleComponents(
1112 ScreenSpaceTransform(), default_scale); 1112 ScreenSpaceTransform(), default_scale);
1113 return std::max(transform_scales.x(), transform_scales.y()); 1113 return std::max(transform_scales.x(), transform_scales.y());
1114 } 1114 }
1115 1115
1116 } // namespace cc 1116 } // namespace cc
OLDNEW
« no previous file with comments | « no previous file | cc/layers/layer_impl_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698