summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--packages/SystemUI/src/com/android/systemui/volume/VolumeDialogImpl.java13
1 files changed, 9 insertions, 4 deletions
diff --git a/packages/SystemUI/src/com/android/systemui/volume/VolumeDialogImpl.java b/packages/SystemUI/src/com/android/systemui/volume/VolumeDialogImpl.java
index c69fb662b67d..857a93692de6 100644
--- a/packages/SystemUI/src/com/android/systemui/volume/VolumeDialogImpl.java
+++ b/packages/SystemUI/src/com/android/systemui/volume/VolumeDialogImpl.java
@@ -285,7 +285,7 @@ public class VolumeDialogImpl implements VolumeDialog, Dumpable,
@GuardedBy("mSafetyWarningLock")
private CsdWarningDialog mCsdDialog;
private boolean mHovering = false;
- private final boolean mShowActiveStreamOnly;
+ private final boolean mIsTv;
private boolean mConfigChanged = false;
private boolean mIsAnimatingDismiss = false;
private boolean mHasSeenODICaptionsTooltip;
@@ -346,7 +346,7 @@ public class VolumeDialogImpl implements VolumeDialog, Dumpable,
mConfigurationController = configurationController;
mMediaOutputDialogManager = mediaOutputDialogManager;
mCsdWarningDialogFactory = csdWarningDialogFactory;
- mShowActiveStreamOnly = showActiveStreamOnly();
+ mIsTv = isTv();
mHasSeenODICaptionsTooltip =
Prefs.getBoolean(context, Prefs.Key.HAS_SEEN_ODI_CAPTIONS_TOOLTIP, false);
mShowLowMediaVolumeIcon =
@@ -1635,7 +1635,7 @@ public class VolumeDialogImpl implements VolumeDialog, Dumpable,
Trace.endSection();
}
- private boolean showActiveStreamOnly() {
+ private boolean isTv() {
return mContext.getPackageManager().hasSystemFeature(PackageManager.FEATURE_LEANBACK)
|| mContext.getPackageManager().hasSystemFeature(PackageManager.FEATURE_TELEVISION);
}
@@ -1647,7 +1647,7 @@ public class VolumeDialogImpl implements VolumeDialog, Dumpable,
return true;
}
- if (!mShowActiveStreamOnly) {
+ if (!mIsTv) {
if (row.stream == AudioSystem.STREAM_ACCESSIBILITY) {
return mShowA11yStream;
}
@@ -2092,6 +2092,11 @@ public class VolumeDialogImpl implements VolumeDialog, Dumpable,
}
final int newProgress = getProgressFromVolume(row.ss, row.slider, vlevel);
if (progress != newProgress) {
+ if (mIsTv) {
+ // don't animate slider on TVs
+ row.slider.setProgress(newProgress, false);
+ return;
+ }
if (mShowing && rowVisible) {
// animate!
if (row.anim != null && row.anim.isRunning()