diff options
author | Roman Birg <roman@cyngn.com> | 2016-05-19 12:36:05 -0700 |
---|---|---|
committer | Roman Birg <roman@cyngn.com> | 2016-05-19 12:36:05 -0700 |
commit | ffb1515c850395870aeb1a7a9db3647c1d58c8a5 (patch) | |
tree | 54c5f0817628e8d13d9dfdc7e3259ea27a413e7b /src | |
parent | 2a5d138c396ba5dcf724a8bdbc7063d025e98e6e (diff) | |
download | android_packages_apps_AudioFX-ffb1515c850395870aeb1a7a9db3647c1d58c8a5.tar.gz android_packages_apps_AudioFX-ffb1515c850395870aeb1a7a9db3647c1d58c8a5.tar.bz2 android_packages_apps_AudioFX-ffb1515c850395870aeb1a7a9db3647c1d58c8a5.zip |
AudioFX: finish swipe animation if hitting off during it
It was possible for the view pager to pause in between presets and did
not allow the user to touch it.
Ticket: AUDIO-151
Change-Id: I5a73e8c2e6a7f1953e3abb9c8376a121946f4f07
Signed-off-by: Roman Birg <roman@cyngn.com>
Diffstat (limited to 'src')
-rw-r--r-- | src/com/cyngn/audiofx/fragment/EqualizerFragment.java | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/src/com/cyngn/audiofx/fragment/EqualizerFragment.java b/src/com/cyngn/audiofx/fragment/EqualizerFragment.java index 14e6c04..96fb3af 100644 --- a/src/com/cyngn/audiofx/fragment/EqualizerFragment.java +++ b/src/com/cyngn/audiofx/fragment/EqualizerFragment.java @@ -38,7 +38,7 @@ public class EqualizerFragment extends AudioFxBaseFragment private static final String TAG = EqualizerFragment.class.getSimpleName(); private static final boolean DEBUG = false; - private static final boolean DEBUG_VIEWPAGER = false; + private static final boolean DEBUG_VIEWPAGER = true; private final ArgbEvaluator mArgbEval = new ArgbEvaluator(); @@ -384,7 +384,9 @@ public class EqualizerFragment extends AudioFxBaseFragment @Override public void onGlobalDeviceToggle(boolean on) { - + if (!on) { + mFakePager.setCurrentItem(mFakePager.getCurrentItem(), true); + } } @@ -508,6 +510,7 @@ public class EqualizerFragment extends AudioFxBaseFragment mEqManager.setChangingPresets(false); mEqManager.setPreset(mSelectedPosition); + } else { // not idle mEqManager.setChangingPresets(true); |