Clamp the duration of rotary animations.
If the user drags the rotary slowly, the spin animation can take a long
time; since the UI is locked for the duration, the user can get stuck
waiting five or more seconds after toggling mute for the rotary to swing
back around. Clamp the animation time to at most one second, so it
always finishes in a reasonable time.
Note that fling velocity is normally used for the velocity that a scrolling
box can be flung; this setting assumes that the user can grab what he flung
again and stop it, which isn't the case here. I think both
mMinimumVelocity and mMaximumVelocity could simply be removed, selecting
some arbitrarily large value as the maximum and leaving mMinimumVelocity
to clamp the minimum speed. I've left them alone here.
Change-Id: I7d2f954ec884637c36ed3d86477e549bdb2ee92a
Signed-off-by:
Glenn Maynard <glenn@zewt.org>
Loading
Please register or sign in to comment