| Index: ui/views/animation/square_ink_drop_ripple.h
|
| diff --git a/ui/views/animation/square_ink_drop_ripple.h b/ui/views/animation/square_ink_drop_ripple.h
|
| index 99913360c89527fe3b67da833127b0d5ec947065..8b34df8f4b515feee5e5b50e2a7a5fe9f0a3daf8 100644
|
| --- a/ui/views/animation/square_ink_drop_ripple.h
|
| +++ b/ui/views/animation/square_ink_drop_ripple.h
|
| @@ -131,15 +131,25 @@ class VIEWS_EXPORT SquareInkDropRipple : public InkDropRipple {
|
|
|
| // Updates all of the Transforms in |transforms_out| for a circle of the given
|
| // |size|.
|
| - void CalculateCircleTransforms(const gfx::Size& size,
|
| + void CalculateCircleTransforms(const gfx::Size& desired_size,
|
| InkDropTransforms* transforms_out) const;
|
|
|
| // Updates all of the Transforms in |transforms_out| for a rounded rectangle
|
| - // of the given |size| and |corner_radius|.
|
| - void CalculateRectTransforms(const gfx::Size& size,
|
| + // of the given |desired_size| and |corner_radius|. The effective size may
|
| + // differ from |desired_size| at certain scale factors to make sure the ripple
|
| + // is pixel-aligned.
|
| + void CalculateRectTransforms(const gfx::Size& desired_size,
|
| float corner_radius,
|
| InkDropTransforms* transforms_out) const;
|
|
|
| + // Calculates a Transform for a circle layer.
|
| + gfx::Transform CalculateCircleTransform(float scale,
|
| + float target_center_x,
|
| + float target_center_y) const;
|
| +
|
| + // Calculates a Transform for a rectangle layer.
|
| + gfx::Transform CalculateRectTransform(float x_scale, float y_scale) const;
|
| +
|
| // Updates all of the Transforms in |transforms_out| to the current Transforms
|
| // of the painted shape Layers.
|
| void GetCurrentTransforms(InkDropTransforms* transforms_out) const;
|
| @@ -159,7 +169,7 @@ class VIEWS_EXPORT SquareInkDropRipple : public InkDropRipple {
|
| ActivatedShape activated_shape_;
|
|
|
| // Ink drop opacity when it is visible.
|
| - const float visible_opacity_;
|
| + float visible_opacity_;
|
|
|
| // Maximum size that an ink drop will be drawn to for any InkDropState whose
|
| // final frame should be large.
|
| @@ -177,6 +187,9 @@ class VIEWS_EXPORT SquareInkDropRipple : public InkDropRipple {
|
| // InkDropState whose final frame should be small.
|
| const int small_corner_radius_;
|
|
|
| + // The center point of the ripple, relative to the root layer's origin.
|
| + gfx::Point center_point_;
|
| +
|
| // ui::LayerDelegate to paint circles for all the circle layers.
|
| std::unique_ptr<CircleLayerDelegate> circle_layer_delegate_;
|
|
|
|
|