diff options
author | Martin Fietz <Martin.Fietz@gmail.com> | 2015-09-04 21:16:35 +0200 |
---|---|---|
committer | Martin Fietz <Martin.Fietz@gmail.com> | 2015-09-05 19:38:09 +0200 |
commit | 1dd87efebd6e987b8e3c07abc56a01e9bf0883bd (patch) | |
tree | 1d7f1ef24cb17870f040f649f3a265fe2564aa77 /app/src/main | |
parent | 7de666f511a0f073255f5eb5aa5d1b88eaffaf8f (diff) | |
download | AntennaPod-1dd87efebd6e987b8e3c07abc56a01e9bf0883bd.zip |
Scale animation when playback speed has been changed via popup
Diffstat (limited to 'app/src/main')
-rw-r--r-- | app/src/main/java/de/danoeh/antennapod/activity/AudioplayerActivity.java | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/app/src/main/java/de/danoeh/antennapod/activity/AudioplayerActivity.java b/app/src/main/java/de/danoeh/antennapod/activity/AudioplayerActivity.java index 480f8a5f8..4a94caefe 100644 --- a/app/src/main/java/de/danoeh/antennapod/activity/AudioplayerActivity.java +++ b/app/src/main/java/de/danoeh/antennapod/activity/AudioplayerActivity.java @@ -22,6 +22,8 @@ import android.view.MenuInflater; import android.view.MenuItem; import android.view.View; import android.view.ViewGroup; +import android.view.animation.LinearInterpolator; +import android.view.animation.ScaleAnimation; import android.widget.AdapterView; import android.widget.ArrayAdapter; import android.widget.Button; @@ -521,6 +523,13 @@ public class AudioplayerActivity extends MediaplayerActivity implements ItemDesc if (popupWindow != null && popupWindow.isShowing()) { popupWindow.dismiss(); } + ScaleAnimation anim = new ScaleAnimation(1.0f, 1.33f, 1.0f, 1.33f, + butPlaybackSpeed.getWidth()/2, butPlaybackSpeed.getHeight()/2); + anim.setDuration(150); + anim.setRepeatMode(ScaleAnimation.REVERSE); + anim.setRepeatCount(1); + anim.setInterpolator(new LinearInterpolator()); + butPlaybackSpeed.startAnimation(anim); } }); popupWindow = new PopupWindow(popupView, |