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

Unified Diff: cc/layers/viewport.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: 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: cc/layers/viewport.cc
diff --git a/cc/layers/viewport.cc b/cc/layers/viewport.cc
index 77ebc2658a971c71e4e2d5cc1421b9d543c88fff..80e711fd027db3979b9d2098ce5578ff6e911685 100644
--- a/cc/layers/viewport.cc
+++ b/cc/layers/viewport.cc
@@ -67,8 +67,8 @@ Viewport::ScrollResult Viewport::ScrollBy(const gfx::Vector2dF& delta,
}
void Viewport::SnapPinchAnchorIfWithinMargin(const gfx::Point& anchor) {
- gfx::SizeF viewport_size =
- host_impl_->active_tree()->InnerViewportContainerLayer()->bounds();
+ gfx::SizeF viewport_size = gfx::SizeF(
vmpstr 2015/09/23 23:04:25 Is this required? what about gfx::SizeF viewpor
danakj 2015/09/23 23:08:20 Ya, but it's less obvious reading the code so I di
+ host_impl_->active_tree()->InnerViewportContainerLayer()->bounds());
if (anchor.x() < kPinchZoomSnapMarginDips)
pinch_anchor_adjustment_.set_x(-anchor.x());

Powered by Google App Engine
This is Rietveld 408576698