| Index: ui/views/animation/ink_drop_animation_controller_impl.cc
|
| diff --git a/ui/views/animation/ink_drop_animation_controller_impl.cc b/ui/views/animation/ink_drop_animation_controller_impl.cc
|
| index 963440d909e6478c60690c7374745207bc219dea..d28a280868bca12e92ff55b783360651ff2fbbaa 100644
|
| --- a/ui/views/animation/ink_drop_animation_controller_impl.cc
|
| +++ b/ui/views/animation/ink_drop_animation_controller_impl.cc
|
| @@ -29,7 +29,7 @@ const int kHoverFadeInAfterAnimationDurationInMs = 250;
|
|
|
| // The duration, in milliseconds, of the hover state fade out animation when it
|
| // is triggered by an ink drop ripple animation starting.
|
| -const int kHoverFadeOutBeforeAnimationDurationInMs = 300;
|
| +const int kHoverFadeOutBeforeAnimationDurationInMs = 120;
|
|
|
| // The amount of time in milliseconds that |hover_| should delay after a ripple
|
| // animation before fading in.
|
| @@ -85,7 +85,8 @@ void InkDropAnimationControllerImpl::AnimateToState(
|
|
|
| if (ink_drop_state != views::InkDropState::HIDDEN) {
|
| SetHoveredInternal(false, base::TimeDelta::FromMilliseconds(
|
| - kHoverFadeOutBeforeAnimationDurationInMs));
|
| + kHoverFadeOutBeforeAnimationDurationInMs),
|
| + true);
|
| }
|
|
|
| ink_drop_animation_->AnimateToState(ink_drop_state);
|
| @@ -96,7 +97,7 @@ void InkDropAnimationControllerImpl::SnapToActivated() {
|
| if (!ink_drop_animation_)
|
| CreateInkDropAnimation();
|
|
|
| - SetHoveredInternal(false, base::TimeDelta());
|
| + SetHoveredInternal(false, base::TimeDelta(), false);
|
|
|
| ink_drop_animation_->SnapToActivated();
|
| }
|
| @@ -107,7 +108,8 @@ void InkDropAnimationControllerImpl::SetHovered(bool is_hovered) {
|
| is_hovered ? base::TimeDelta::FromMilliseconds(
|
| kHoverFadeInFromUserInputDurationInMs)
|
| : base::TimeDelta::FromMilliseconds(
|
| - kHoverFadeOutFromUserInputDurationInMs));
|
| + kHoverFadeOutFromUserInputDurationInMs),
|
| + false);
|
| }
|
|
|
| void InkDropAnimationControllerImpl::DestroyHiddenTargetedAnimations() {
|
| @@ -175,7 +177,8 @@ void InkDropAnimationControllerImpl::InkDropAnimationEnded(
|
|
|
| void InkDropAnimationControllerImpl::SetHoveredInternal(
|
| bool is_hovered,
|
| - base::TimeDelta animation_duration) {
|
| + base::TimeDelta animation_duration,
|
| + bool explode) {
|
| StopHoverAfterAnimationTimer();
|
|
|
| if (IsHoverFadingInOrVisible() == is_hovered)
|
| @@ -186,7 +189,7 @@ void InkDropAnimationControllerImpl::SetHoveredInternal(
|
| if (hover_ && !IsVisible())
|
| hover_->FadeIn(animation_duration);
|
| } else {
|
| - hover_->FadeOut(animation_duration);
|
| + hover_->FadeOut(animation_duration, explode);
|
| }
|
| }
|
|
|
| @@ -210,7 +213,8 @@ void InkDropAnimationControllerImpl::StopHoverAfterAnimationTimer() {
|
|
|
| void InkDropAnimationControllerImpl::HoverAfterAnimationTimerFired() {
|
| SetHoveredInternal(true, base::TimeDelta::FromMilliseconds(
|
| - kHoverFadeInAfterAnimationDurationInMs));
|
| + kHoverFadeInAfterAnimationDurationInMs),
|
| + true);
|
| hover_after_animation_timer_.reset();
|
| }
|
|
|
|
|