From 437ae9552cce7768068fa92663740711ee541417 Mon Sep 17 00:00:00 2001 From: linyuh Date: Mon, 26 Mar 2018 12:46:18 -0700 Subject: Remove obsolete version checks and compat utilities after min SDK was bumped up to N. Test: Existing tests PiperOrigin-RevId: 190508397 Change-Id: Ia5f33e45af1d1cc666fec5f43efa564b2b68c193 --- java/com/android/dialer/util/DialerUtils.java | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) (limited to 'java/com/android/dialer/util/DialerUtils.java') diff --git a/java/com/android/dialer/util/DialerUtils.java b/java/com/android/dialer/util/DialerUtils.java index 7f7b9da74..49a07334f 100644 --- a/java/com/android/dialer/util/DialerUtils.java +++ b/java/com/android/dialer/util/DialerUtils.java @@ -15,6 +15,7 @@ */ package com.android.dialer.util; +import android.annotation.SuppressLint; import android.app.AlertDialog; import android.content.ActivityNotFoundException; import android.content.Context; @@ -22,8 +23,6 @@ import android.content.DialogInterface; import android.content.DialogInterface.OnClickListener; import android.content.Intent; import android.graphics.Point; -import android.os.Build.VERSION; -import android.os.Build.VERSION_CODES; import android.os.Bundle; import android.telecom.TelecomManager; import android.telephony.TelephonyManager; @@ -131,12 +130,12 @@ public class DialerUtils { * currently active call over LTE. Regardless of the country or carrier, the radio will drop an * active LTE call if a WPS number is dialed, so this warning is necessary. */ + @SuppressLint("MissingPermission") private static boolean shouldWarnForOutgoingWps(Context context, String number) { if (number != null && number.startsWith(WPS_PREFIX)) { TelephonyManager telephonyManager = context.getSystemService(TelephonyManager.class); boolean isOnVolte = - VERSION.SDK_INT >= VERSION_CODES.N - && telephonyManager.getVoiceNetworkType() == TelephonyManager.NETWORK_TYPE_LTE; + telephonyManager.getVoiceNetworkType() == TelephonyManager.NETWORK_TYPE_LTE; boolean hasCurrentActiveCall = telephonyManager.getCallState() == TelephonyManager.CALL_STATE_OFFHOOK; return isOnVolte && hasCurrentActiveCall; -- cgit v1.2.3