Merge "Deprecate acceptRingingCall and endCall." am: 6e3a88a3e2 am: 280019629c

am: 994c17768a

Change-Id: I10fee83408de8a1af75555eedf2403dfdbc4b857
This commit is contained in:
Tyler Gunn
2019-02-01 13:06:23 -08:00
committed by android-build-merger
2 changed files with 16 additions and 3 deletions

View File

@@ -1404,8 +1404,14 @@ public class TelecomManager {
*
* @return {@code true} if there is a call which will be rejected or terminated, {@code false}
* otherwise.
* @deprecated Companion apps for wearable devices should use the {@link InCallService} API
* instead. Apps performing call screening should use the {@link CallScreeningService} API
* instead.
*/
@RequiresPermission(Manifest.permission.ANSWER_PHONE_CALLS)
@Deprecated
public boolean endCall() {
try {
if (isServiceConnected()) {
@@ -1426,11 +1432,15 @@ public class TelecomManager {
*
* Requires permission: {@link android.Manifest.permission#MODIFY_PHONE_STATE} or
* {@link android.Manifest.permission#ANSWER_PHONE_CALLS}
*
* @deprecated Companion apps for wearable devices should use the {@link InCallService} API
* instead.
*/
//TODO: L-release - need to convert all invocation of ITelecmmService#answerRingingCall to use
// this method (clockwork & gearhead).
@RequiresPermission(anyOf =
{Manifest.permission.ANSWER_PHONE_CALLS, Manifest.permission.MODIFY_PHONE_STATE})
@Deprecated
public void acceptRingingCall() {
try {
if (isServiceConnected()) {
@@ -1449,9 +1459,12 @@ public class TelecomManager {
* {@link android.Manifest.permission#ANSWER_PHONE_CALLS}
*
* @param videoState The desired video state to answer the call with.
* @deprecated Companion apps for wearable devices should use the {@link InCallService} API
* instead.
*/
@RequiresPermission(anyOf =
{Manifest.permission.ANSWER_PHONE_CALLS, Manifest.permission.MODIFY_PHONE_STATE})
@Deprecated
public void acceptRingingCall(int videoState) {
try {
if (isServiceConnected()) {