diff options
author | Treehugger Robot <treehugger-gerrit@google.com> | 2017-10-12 23:02:32 +0000 |
---|---|---|
committer | Gerrit Code Review <noreply-gerritcodereview@google.com> | 2017-10-12 23:02:32 +0000 |
commit | 5f57e30484848b7b0b8d3fbdfe8b32338aa641a5 (patch) | |
tree | 5a37619a955212672a57d86ef50587b3545805ac /java/com/android/incallui/CallerInfoUtils.java | |
parent | 2633778c274746a35e4a54266a3319c53fd1cded (diff) | |
parent | 392f8cd64936a626cc035ac9bb0302094d8dd957 (diff) |
Merge changes I14a2c0b6,Ic67566c2,Id0ef9164,Iec48f030,Ibe1f9de6, ...
* changes:
Handle invalid PhoneAccountHandle component name in MissedCallNotifier
Use TelephonyManagerCompat for IS_REFRESH
Updated animation to enter and exit search ui.
Optimization for incoming call latency.
Fix for voice screen showing for a short time when making a video call
Fix incallui to use latest ux mocks for assisted dialing.
Remove voicemail count changed check for legacy notifications
Diffstat (limited to 'java/com/android/incallui/CallerInfoUtils.java')
-rw-r--r-- | java/com/android/incallui/CallerInfoUtils.java | 22 |
1 files changed, 1 insertions, 21 deletions
diff --git a/java/com/android/incallui/CallerInfoUtils.java b/java/com/android/incallui/CallerInfoUtils.java index bf586f504..38043eda8 100644 --- a/java/com/android/incallui/CallerInfoUtils.java +++ b/java/com/android/incallui/CallerInfoUtils.java @@ -16,15 +16,10 @@ package com.android.incallui; -import android.Manifest.permission; import android.content.Context; import android.content.Loader; import android.content.Loader.OnLoadCompleteListener; -import android.content.pm.PackageManager; import android.net.Uri; -import android.support.annotation.NonNull; -import android.support.v4.content.ContextCompat; -import android.telecom.PhoneAccount; import android.telecom.TelecomManager; import android.text.TextUtils; import com.android.contacts.common.model.Contact; @@ -34,7 +29,6 @@ import com.android.dialer.phonenumbercache.CachedNumberLookupService; import com.android.dialer.phonenumbercache.CachedNumberLookupService.CachedContactInfo; import com.android.dialer.phonenumbercache.ContactInfo; import com.android.dialer.phonenumberutil.PhoneNumberHelper; -import com.android.dialer.telecom.TelecomUtil; import com.android.dialer.util.PermissionsUtil; import com.android.incallui.call.DialerCall; import java.util.Arrays; @@ -112,7 +106,7 @@ public class CallerInfoUtils { // Because the InCallUI is immediately launched before the call is connected, occasionally // a voicemail call will be passed to InCallUI as a "voicemail:" URI without a number. // This call should still be handled as a voicemail call. - if (isVoiceMailNumber(context, call)) { + if (call.isVoiceMailNumber()) { info.markAsVoiceMail(context); } @@ -146,20 +140,6 @@ public class CallerInfoUtils { return cacheInfo; } - public static boolean isVoiceMailNumber(Context context, @NonNull DialerCall call) { - if (call.getHandle() != null - && PhoneAccount.SCHEME_VOICEMAIL.equals(call.getHandle().getScheme())) { - return true; - } - - if (ContextCompat.checkSelfPermission(context, permission.READ_PHONE_STATE) - != PackageManager.PERMISSION_GRANTED) { - return false; - } - - return TelecomUtil.isVoicemailNumber(context, call.getAccountHandle(), call.getNumber()); - } - /** * Handles certain "corner cases" for CNAP. When we receive weird phone numbers from the network * to indicate different number presentations, convert them to expected number and presentation |