This commit is contained in:
Mysochenko Yuriy
2022-05-09 14:45:47 +03:00
parent 21ef2c3482
commit dbed416171
4 changed files with 59 additions and 3 deletions

View File

@ -32,6 +32,16 @@ class CallManager {
}
}
fun toggleHold(): Boolean {
val isOnHold = getState() == Call.STATE_HOLDING
if (isOnHold) {
call?.unhold()
} else {
call?.hold()
}
return !isOnHold
}
fun registerCallback(callback: Call.Callback) {
call?.registerCallback(callback)
}