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

Unified Diff: chrome/browser/thumbnails/simple_thumbnail_crop.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
Index: chrome/browser/thumbnails/simple_thumbnail_crop.cc
diff --git a/chrome/browser/thumbnails/simple_thumbnail_crop.cc b/chrome/browser/thumbnails/simple_thumbnail_crop.cc
index 102fd61b826a7d46114093d23b09b40f385e9e2a..debdfa42936de3e24bd158a47e6c5ce552d6b9f1 100644
--- a/chrome/browser/thumbnails/simple_thumbnail_crop.cc
+++ b/chrome/browser/thumbnails/simple_thumbnail_crop.cc
@@ -90,7 +90,7 @@ gfx::Size SimpleThumbnailCrop::GetCopySizeForThumbnail(
scale_factor = ui::SCALE_FACTOR_200P;
}
float scale = GetScaleForScaleFactor(scale_factor);
- return gfx::ToFlooredSize(gfx::ScaleSize(thumbnail_size, scale));
+ return gfx::ScaleToFlooredSize(thumbnail_size, scale);
}
gfx::Rect SimpleThumbnailCrop::GetClippingRect(const gfx::Size& source_size,
@@ -141,7 +141,7 @@ gfx::Size SimpleThumbnailCrop::ComputeTargetSizeAtMaximumScale(
// TODO(mazda|oshima): Update thumbnail when the max scale factor changes.
// crbug.com/159157.
float max_scale_factor = gfx::ImageSkia::GetMaxSupportedScale();
- return gfx::ToFlooredSize(gfx::ScaleSize(given_size, max_scale_factor));
+ return gfx::ScaleToFlooredSize(given_size, max_scale_factor);
}
SimpleThumbnailCrop::~SimpleThumbnailCrop() {
« no previous file with comments | « chrome/browser/themes/browser_theme_pack.cc ('k') | chrome/browser/thumbnails/simple_thumbnail_crop_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698