diff options
Diffstat (limited to 'packages/SystemUI/src/com/android/systemui/ExpandHelper.java')
-rw-r--r-- | packages/SystemUI/src/com/android/systemui/ExpandHelper.java | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/packages/SystemUI/src/com/android/systemui/ExpandHelper.java b/packages/SystemUI/src/com/android/systemui/ExpandHelper.java index 006619b..bbda536 100644 --- a/packages/SystemUI/src/com/android/systemui/ExpandHelper.java +++ b/packages/SystemUI/src/com/android/systemui/ExpandHelper.java @@ -21,6 +21,7 @@ import android.animation.Animator; import android.animation.AnimatorListenerAdapter; import android.animation.ObjectAnimator; import android.content.Context; +import android.media.AudioAttributes; import android.media.AudioManager; import android.os.Vibrator; import android.util.Log; @@ -66,6 +67,11 @@ public class ExpandHelper implements Gefingerpoken { // overstretch fills the range (GLOW_BASE, 1.0] private static final float GLOW_BASE = 0.5f; + private static final AudioAttributes VIBRATION_ATTRIBUTES = new AudioAttributes.Builder() + .setContentType(AudioAttributes.CONTENT_TYPE_SONIFICATION) + .setUsage(AudioAttributes.USAGE_ASSISTANCE_SONIFICATION) + .build(); + @SuppressWarnings("unused") private Context mContext; @@ -550,7 +556,7 @@ public class ExpandHelper implements Gefingerpoken { mVibrator = (android.os.Vibrator) mContext.getSystemService(Context.VIBRATOR_SERVICE); } - mVibrator.vibrate(duration, AudioManager.STREAM_SYSTEM); + mVibrator.vibrate(duration, VIBRATION_ATTRIBUTES); } } |