From 2a5098f888377695fcf8578fd529b277dd873713 Mon Sep 17 00:00:00 2001 From: Shuo Qian Date: Tue, 9 Apr 2019 11:40:32 -0700 Subject: [PATCH] Use Received Uri as Gateway Uri Gateway information is the core component to perform redirection. We should clarify the uri we received from CallRedirectionService is gateway Uri. And apply it in Telecom. Test: Treehugger; Manual Bug: 130048865 Change-Id: I3599377406b88751ee11139e9a1aa5afab734f7c Merged-In: I3599377406b88751ee11139e9a1aa5afab734f7c --- telecomm/java/android/telecom/CallRedirectionService.java | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/telecomm/java/android/telecom/CallRedirectionService.java b/telecomm/java/android/telecom/CallRedirectionService.java index 37fab09cd7453..36c637723c0a6 100644 --- a/telecomm/java/android/telecom/CallRedirectionService.java +++ b/telecomm/java/android/telecom/CallRedirectionService.java @@ -119,18 +119,18 @@ public abstract class CallRedirectionService extends Service { * {@link #onPlaceCall(Uri, PhoneAccountHandle, boolean)}. The response corresponds to the * latest request via {@link #onPlaceCall(Uri, PhoneAccountHandle, boolean)}. * - * @param handle the new phone number to dial + * @param gatewayUri the gateway uri for call redirection. * @param targetPhoneAccount the {@link PhoneAccountHandle} to use when placing the call. * @param confirmFirst Telecom will ask users to confirm the redirection via a yes/no dialog * if the confirmFirst is true, and if the redirection request of this * response was sent with a true flag of allowInteractiveResponse via * {@link #onPlaceCall(Uri, PhoneAccountHandle, boolean)} */ - public final void redirectCall(@NonNull Uri handle, + public final void redirectCall(@NonNull Uri gatewayUri, @NonNull PhoneAccountHandle targetPhoneAccount, boolean confirmFirst) { try { - mCallRedirectionAdapter.redirectCall(handle, targetPhoneAccount, confirmFirst); + mCallRedirectionAdapter.redirectCall(gatewayUri, targetPhoneAccount, confirmFirst); } catch (RemoteException e) { e.rethrowAsRuntimeException(); }