add inCall tone for in call quality notification am: 4b8b1f52f8 am: af7a21ab07 am: a04942d0c3
Original change: https://android-review.googlesource.com/c/platform/packages/services/Telecomm/+/1618591
MUST ONLY BE SUBMITTED BY AUTOMERGER
Change-Id: Iced1e6bee66d787f02f73c2a7c40adc285951586
diff --git a/res/raw/InCallQualityNotification.ogg b/res/raw/InCallQualityNotification.ogg
new file mode 100644
index 0000000..84c029a
--- /dev/null
+++ b/res/raw/InCallQualityNotification.ogg
Binary files differ
diff --git a/src/com/android/server/telecom/InCallTonePlayer.java b/src/com/android/server/telecom/InCallTonePlayer.java
index 814c730..7500436 100644
--- a/src/com/android/server/telecom/InCallTonePlayer.java
+++ b/src/com/android/server/telecom/InCallTonePlayer.java
@@ -163,6 +163,7 @@
public static final int TONE_VOICE_PRIVACY = 13;
public static final int TONE_VIDEO_UPGRADE = 14;
public static final int TONE_RTT_REQUEST = 15;
+ public static final int TONE_IN_CALL_QUALITY_NOTIFICATION = 16;
private static final int TONE_RESOURCE_ID_UNDEFINED = -1;
@@ -337,6 +338,15 @@
toneLengthMillis = 4000;
mediaResourceId = TONE_RESOURCE_ID_UNDEFINED;
break;
+ case TONE_IN_CALL_QUALITY_NOTIFICATION:
+ // Don't use tone generator
+ toneType = ToneGenerator.TONE_UNKNOWN;
+ toneVolume = RELATIVE_VOLUME_UNDEFINED;
+ toneLengthMillis = 0;
+
+ // Use a tone resource file for a more rich, full-bodied tone experience.
+ mediaResourceId = R.raw.InCallQualityNotification;
+ break;
default:
throw new IllegalStateException("Bad toneId: " + mToneId);
}