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

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

Issue 12704023: Remove CalculateContentsScale max texture size DCHECK. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Re-enable another test Created 7 years, 9 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 | « android_webview/javatests/src/org/chromium/android_webview/test/AwSettingsTest.java ('k') | no next file » | 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/scrollbar_layer.h" 5 #include "cc/layers/scrollbar_layer.h"
6 6
7 #include "base/basictypes.h" 7 #include "base/basictypes.h"
8 #include "base/debug/trace_event.h" 8 #include "base/debug/trace_event.h"
9 #include "cc/layers/scrollbar_layer_impl.h" 9 #include "cc/layers/scrollbar_layer_impl.h"
10 #include "cc/resources/caching_bitmap_content_layer_updater.h" 10 #include "cc/resources/caching_bitmap_content_layer_updater.h"
(...skipping 85 matching lines...) Expand 10 before | Expand all | Expand 10 after
96 bool animating_transform_to_screen, 96 bool animating_transform_to_screen,
97 float* contents_scale_x, 97 float* contents_scale_x,
98 float* contents_scale_y, 98 float* contents_scale_y,
99 gfx::Size* content_bounds) { 99 gfx::Size* content_bounds) {
100 ContentsScalingLayer::CalculateContentsScale( 100 ContentsScalingLayer::CalculateContentsScale(
101 ClampScaleToMaxTextureSize(ideal_contents_scale), 101 ClampScaleToMaxTextureSize(ideal_contents_scale),
102 animating_transform_to_screen, 102 animating_transform_to_screen,
103 contents_scale_x, 103 contents_scale_x,
104 contents_scale_y, 104 contents_scale_y,
105 content_bounds); 105 content_bounds);
106 DCHECK_LE(content_bounds->width(), MaxTextureSize());
danakj 2013/03/25 21:52:10 How about doing these if you're not in solid color
107 DCHECK_LE(content_bounds->height(), MaxTextureSize());
108 } 106 }
109 107
110 void ScrollbarLayer::PushPropertiesTo(LayerImpl* layer) { 108 void ScrollbarLayer::PushPropertiesTo(LayerImpl* layer) {
111 ContentsScalingLayer::PushPropertiesTo(layer); 109 ContentsScalingLayer::PushPropertiesTo(layer);
112 110
113 ScrollbarLayerImpl* scrollbar_layer = static_cast<ScrollbarLayerImpl*>(layer); 111 ScrollbarLayerImpl* scrollbar_layer = static_cast<ScrollbarLayerImpl*>(layer);
114 112
115 scrollbar_layer->SetScrollbarData(scrollbar_.get()); 113 scrollbar_layer->SetScrollbarData(scrollbar_.get());
116 scrollbar_layer->SetThumbSize(thumb_size_); 114 scrollbar_layer->SetThumbSize(thumb_size_);
117 115
(...skipping 314 matching lines...) Expand 10 before | Expand all | Expand 10 after
432 thumb_.get(), 430 thumb_.get(),
433 origin_thumb_rect, 431 origin_thumb_rect,
434 queue, 432 queue,
435 stats); 433 stats);
436 } 434 }
437 435
438 dirty_rect_ = gfx::RectF(); 436 dirty_rect_ = gfx::RectF();
439 } 437 }
440 438
441 } // namespace cc 439 } // namespace cc
OLDNEW
« no previous file with comments | « android_webview/javatests/src/org/chromium/android_webview/test/AwSettingsTest.java ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698