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

Unified Diff: ui/views/animation/flood_fill_ink_drop_ripple.cc

Issue 2042073002: Centered flood fill style ink drop ripples on mouse/touch points. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Polished for review. Created 4 years, 6 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: ui/views/animation/flood_fill_ink_drop_ripple.cc
diff --git a/ui/views/animation/flood_fill_ink_drop_ripple.cc b/ui/views/animation/flood_fill_ink_drop_ripple.cc
index 9abd3e750fe62bcd8dea0c0b42de1cef5aea5a55..21c332dfa646edd37a2d83d0a14fcf395d6a4714 100644
--- a/ui/views/animation/flood_fill_ink_drop_ripple.cc
+++ b/ui/views/animation/flood_fill_ink_drop_ripple.cc
@@ -316,12 +316,8 @@ gfx::Transform FloodFillInkDropRipple::CalculateTransform(
}
gfx::Transform FloodFillInkDropRipple::GetMaxSizeTargetTransform() const {
- // TODO(estade): get rid of this 2, but make the fade out start before the
- // active/action transform is done.
- return CalculateTransform(gfx::Vector2dF(root_layer_.bounds().width(),
- root_layer_.bounds().height())
- .Length() /
- 2);
+ return CalculateTransform(
+ root_layer_.bounds().MaxDistanceToCorners(center_point_));
}
} // namespace views

Powered by Google App Engine
This is Rietveld 408576698