summaryrefslogtreecommitdiff
path: root/framework/src/android
diff options
context:
space:
mode:
authorRakesh Raghava <rakeshraghava@google.com>2022-04-11 20:53:10 +0000
committerRakesh Raghava <rakeshraghava@google.com>2022-04-12 17:14:39 +0000
commit9bf1a6c09eb7a577e025ad1bbb3dac1b01a33434 (patch)
tree667f09116468801c28b7d7de1f511fd4dde2a417 /framework/src/android
parenteb6d2613214d7a7d1315f9ecdac98c94eef76663 (diff)
downloadImsMedia-9bf1a6c09eb7a577e025ad1bbb3dac1b01a33434.tar.gz
(ImsMedia) Changed Dtmf APIs
- startDtmf(char dtmfDigit, int volume, int duration) updated to sendDtmf(char dtmfDigit, int duration) - stopDtmf() removed Bug: 228134488 Test: build (mm) Change-Id: I0bea96b3a0067fe2bd99f963142a507d2e5b9270
Diffstat (limited to 'framework/src/android')
-rw-r--r--framework/src/android/telephony/imsmedia/IImsAudioSession.aidl3
-rw-r--r--framework/src/android/telephony/imsmedia/ImsAudioSession.java24
2 files changed, 6 insertions, 21 deletions
diff --git a/framework/src/android/telephony/imsmedia/IImsAudioSession.aidl b/framework/src/android/telephony/imsmedia/IImsAudioSession.aidl
index ecd494a6..8013b6c5 100644
--- a/framework/src/android/telephony/imsmedia/IImsAudioSession.aidl
+++ b/framework/src/android/telephony/imsmedia/IImsAudioSession.aidl
@@ -32,8 +32,7 @@ interface IImsAudioSession {
oneway void addConfig(in AudioConfig config);
oneway void deleteConfig(in AudioConfig config);
oneway void confirmConfig(in AudioConfig config);
- oneway void startDtmf(char dtmfDigit, int volume, int duration);
- oneway void stopDtmf();
+ oneway void sendDtmf(char dtmfDigit, int duration);
oneway void sendHeaderExtension(in List<RtpHeaderExtension> extensions);
oneway void setMediaQualityThreshold(in MediaQualityThreshold threshold);
}
diff --git a/framework/src/android/telephony/imsmedia/ImsAudioSession.java b/framework/src/android/telephony/imsmedia/ImsAudioSession.java
index 0be1d877..08edde6e 100644
--- a/framework/src/android/telephony/imsmedia/ImsAudioSession.java
+++ b/framework/src/android/telephony/imsmedia/ImsAudioSession.java
@@ -20,7 +20,6 @@ import android.os.IBinder;
import android.os.RemoteException;
import android.telephony.ims.RtpHeaderExtension;
import android.util.Log;
-
import java.util.List;
/**
@@ -137,29 +136,16 @@ public class ImsAudioSession implements ImsMediaSession {
}
/**
- * Start sending DTMF digit until the duration expires or a stopDtmf() API
- * is received. If the implementation is currently playing a DTMF tone, that
- * tone must be stopped first using stopDtmf().
+ * Send DTMF digit until the duration expires.
*
* @param dtmfDigit single char having one of 12 values: 0-9, *, #
- * @param volume of the DTMF digit between 0 and -63 dBm dropping the sign.
- * @param duration of the key press in milliseconds. -1 means no duration
- * is passed and the caller will invoke stopDtmf().
+ * @param duration of the key press in milliseconds.
*/
- public void startDtmf(final char dtmfDigit, final int volume, final int duration) {
- try {
- miSession.startDtmf(dtmfDigit, volume, duration);
- } catch (RemoteException e) {
- Log.e(TAG, "Failed to start DTMF: " + e);
- }
- }
-
- /** Stop sending the last DTMF digit */
- public void stopDtmf() {
+ public void sendDtmf(final char dtmfDigit, final int duration) {
try {
- miSession.stopDtmf();
+ miSession.sendDtmf(dtmfDigit, duration);
} catch (RemoteException e) {
- Log.e(TAG, "Failed to stop DTMF: " + e);
+ Log.e(TAG, "Failed to send DTMF: " + e);
}
}