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

Unified Diff: cc/tiles/picture_layer_tiling.cc

Issue 1357423009: gfx: Make conversions from Size to SizeF be explicit. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: sizefconvert-gfx: . Created 5 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « cc/test/layer_tree_test.cc ('k') | cc/tiles/picture_layer_tiling_set_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/tiles/picture_layer_tiling.cc
diff --git a/cc/tiles/picture_layer_tiling.cc b/cc/tiles/picture_layer_tiling.cc
index 29255d559201e3d3049a1a2a772da5b37cabffda..be8a7940f7048522a7e13e928e3b50a4f71c513c 100644
--- a/cc/tiles/picture_layer_tiling.cc
+++ b/cc/tiles/picture_layer_tiling.cc
@@ -74,12 +74,12 @@ PictureLayerTiling::PictureLayerTiling(
has_eventually_rect_tiles_(false),
all_tiles_done_(true) {
DCHECK(!raster_source->IsSolidColor());
- gfx::Size content_bounds = gfx::ToCeiledSize(
- gfx::ScaleSize(raster_source_->GetSize(), contents_scale));
+ gfx::Size content_bounds =
+ gfx::ScaleToCeiledSize(raster_source_->GetSize(), contents_scale);
gfx::Size tile_size = client_->CalculateTileSize(content_bounds);
- DCHECK(!gfx::ToFlooredSize(gfx::ScaleSize(raster_source_->GetSize(),
- contents_scale)).IsEmpty())
+ DCHECK(!gfx::ScaleToFlooredSize(raster_source_->GetSize(), contents_scale)
+ .IsEmpty())
<< "Tiling created with scale too small as contents become empty."
<< " Layer bounds: " << raster_source_->GetSize().ToString()
<< " Contents scale: " << contents_scale;
@@ -211,7 +211,7 @@ void PictureLayerTiling::SetRasterSourceAndResize(
raster_source_.swap(raster_source);
gfx::Size new_layer_bounds = raster_source_->GetSize();
gfx::Size content_bounds =
- gfx::ToCeiledSize(gfx::ScaleSize(new_layer_bounds, contents_scale_));
+ gfx::ScaleToCeiledSize(new_layer_bounds, contents_scale_);
gfx::Size tile_size = client_->CalculateTileSize(content_bounds);
if (tile_size != tiling_data_.max_texture_size()) {
« no previous file with comments | « cc/test/layer_tree_test.cc ('k') | cc/tiles/picture_layer_tiling_set_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698