Play auto-answer sound when auto-answering
This commit is contained in:
@ -116,7 +116,7 @@ class Account(val accp: String) {
|
||||
"$res;mwi=yes;vm_uri=\"$vmUri\""
|
||||
|
||||
if (answerMode == Api.ANSWERMODE_AUTO)
|
||||
res += ";answermode=auto"
|
||||
res += ";answermode=auto;answerdelay=1000"
|
||||
|
||||
res += ";ptime=20;regint=${regint};regq=0.5;pubint=0;call_transfer=yes"
|
||||
|
||||
|
||||
@ -545,6 +545,8 @@ class BaresipService: Service() {
|
||||
startRinging()
|
||||
}
|
||||
} else {
|
||||
val mediaPlayer = MediaPlayer.create(this, R.raw.autoanswer)
|
||||
mediaPlayer.start()
|
||||
val newIntent = Intent(this, MainActivity::class.java)
|
||||
newIntent.flags = Intent.FLAG_ACTIVITY_SINGLE_TOP or Intent.FLAG_ACTIVITY_CLEAR_TOP or
|
||||
Intent.FLAG_ACTIVITY_NEW_TASK
|
||||
|
||||
BIN
app/src/main/res/raw/autoanswer.wav
Normal file
BIN
app/src/main/res/raw/autoanswer.wav
Normal file
Binary file not shown.
Reference in New Issue
Block a user