IMS: Propagate media profile changed message
- RTT Voice information will be passed to the UI via
media profile changed message
- The RTT voice information - SPEECH/SILENCE, will be conveyed
via the ImsStreamMediaProfile.hasRttAudioSpeech
- A connection event will be sent from frameworks to the UI -
EVENT_RTT_AUDIO_INDICATION_CHANGED
- Add listeners, connection event and extras to propagate
media profile changed to the UI
Test: Manual
Bug: 110976450
Change-Id: I34d2dd612915d65f5047986dabece968c78f0abe
diff --git a/telecomm/java/android/telecom/Connection.java b/telecomm/java/android/telecom/Connection.java
index 8425603..05d5a13 100644
--- a/telecomm/java/android/telecom/Connection.java
+++ b/telecomm/java/android/telecom/Connection.java
@@ -505,6 +505,14 @@
"android.telecom.extra.ORIGINAL_CONNECTION_ID";
/**
+ * Boolean connection extra key set on the extras passed to
+ * {@link Connection#sendConnectionEvent} which indicates that audio is present
+ * on the RTT call when the extra value is true.
+ */
+ public static final String EXTRA_IS_RTT_AUDIO_PRESENT =
+ "android.telecom.extra.IS_RTT_AUDIO_PRESENT";
+
+ /**
* Connection event used to inform Telecom that it should play the on hold tone. This is used
* to play a tone when the peer puts the current call on hold. Sent to Telecom via
* {@link #sendConnectionEvent(String, Bundle)}.
@@ -619,6 +627,13 @@
*/
public static final String EXTRA_SIP_INVITE = "android.telecom.extra.SIP_INVITE";
+ /**
+ * Connection event used to inform an {@link InCallService} that the RTT audio indication
+ * has changed.
+ */
+ public static final String EVENT_RTT_AUDIO_INDICATION_CHANGED =
+ "android.telecom.event.RTT_AUDIO_INDICATION_CHANGED";
+
// Flag controlling whether PII is emitted into the logs
private static final boolean PII_DEBUG = Log.isLoggable(android.util.Log.DEBUG);