From 8033ae2954263a21eea6b1ff2a21b4ee6a75eead Mon Sep 17 00:00:00 2001 From: erfanian Date: Mon, 8 Jan 2018 10:43:27 -0800 Subject: Use support lib to determine build version. Test: none PiperOrigin-RevId: 181185206 Change-Id: I167d9604285f7d5af4f34c6417d0ce1263e64fa1 --- java/com/android/dialer/precall/impl/AssistedDialAction.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/java/com/android/dialer/precall/impl/AssistedDialAction.java b/java/com/android/dialer/precall/impl/AssistedDialAction.java index 77c93279b..8d2b17603 100644 --- a/java/com/android/dialer/precall/impl/AssistedDialAction.java +++ b/java/com/android/dialer/precall/impl/AssistedDialAction.java @@ -20,6 +20,7 @@ import android.annotation.TargetApi; import android.content.Context; import android.os.Build; import android.os.Bundle; +import android.support.v4.os.BuildCompat; import android.telecom.PhoneAccount; import android.telephony.SubscriptionInfo; import android.telephony.TelephonyManager; @@ -57,7 +58,7 @@ public class AssistedDialAction implements PreCallAction { AssistedDialingMediator assistedDialingMediator = ConcreteCreator.createNewAssistedDialingMediator( getAssistedDialingTelephonyManager(context, builder), context); - if (Build.VERSION.SDK_INT > ConcreteCreator.BUILD_CODE_CEILING) { + if (BuildCompat.isAtLeastP()) { builder.getOutgoingCallExtras().putBoolean(TelephonyManagerCompat.USE_ASSISTED_DIALING, true); } // Checks the platform is N+ and meets other pre-flight checks. -- cgit v1.2.3