diff options
author | Treehugger Robot <treehugger-gerrit@google.com> | 2018-06-27 19:53:55 +0000 |
---|---|---|
committer | Gerrit Code Review <noreply-gerritcodereview@google.com> | 2018-06-27 19:53:55 +0000 |
commit | 1b4ec7b954ba2d8efae2f383697babe54b795f67 (patch) | |
tree | 4c051c4a8702f4256f83f0e55182e27b2ed5b840 /java/com/android/dialer/assisteddialing/ConcreteCreator.java | |
parent | cae28c6d5c04a79fb058043ce0c3e043e610309a (diff) | |
parent | d637af51091dc86a197da6520484e10a356a421b (diff) |
Merge changes I0f1ed20a,Ia68d3b13,I72047d59,Ieff3c7fb,I53c3896a, ...
* changes:
Added method to set Save and Redo buttons enabled/disabled Added logic to setState() method to change state of buttons
Update emergency call map and device number UI.
Fix SpeedDialUiItem.getDefaultVoiceChannel
Fix an AOSP build error caused by version codes
Update connection label.
Remove redundant version checks and annotations in the assisted dialing package.
Diffstat (limited to 'java/com/android/dialer/assisteddialing/ConcreteCreator.java')
-rw-r--r-- | java/com/android/dialer/assisteddialing/ConcreteCreator.java | 14 |
1 files changed, 4 insertions, 10 deletions
diff --git a/java/com/android/dialer/assisteddialing/ConcreteCreator.java b/java/com/android/dialer/assisteddialing/ConcreteCreator.java index 050774340..b4f926dd3 100644 --- a/java/com/android/dialer/assisteddialing/ConcreteCreator.java +++ b/java/com/android/dialer/assisteddialing/ConcreteCreator.java @@ -16,13 +16,10 @@ package com.android.dialer.assisteddialing; -import android.annotation.TargetApi; import android.content.Context; import android.os.Build; -import android.os.Build.VERSION_CODES; import android.preference.PreferenceManager; import android.support.annotation.NonNull; -import android.support.annotation.VisibleForTesting; import android.support.v4.os.UserManagerCompat; import android.telephony.TelephonyManager; import com.android.dialer.common.LogUtil; @@ -36,13 +33,11 @@ import com.android.dialer.strictmode.StrictModeUtils; * <p>This helps keep the dependencies required by AssistedDialingMediator for assisted dialing * explicit. */ -@TargetApi(VERSION_CODES.N) public final class ConcreteCreator { - // Floor set at N due to use of Optional. - @VisibleForTesting public static final int BUILD_CODE_FLOOR = Build.VERSION_CODES.N; - // Ceiling set at P because this feature will ship as part of the framework in Q. - @VisibleForTesting public static final int BUILD_CODE_CEILING = 28; + // Ceiling set at P (version code 28) because this feature will ship as part of the framework in + // Q. + public static final int BUILD_CODE_CEILING = 28; /** * Creates a new AssistedDialingMediator @@ -105,8 +100,7 @@ public final class ConcreteCreator { throw new NullPointerException("Provided configProvider was null"); } - return (Build.VERSION.SDK_INT >= BUILD_CODE_FLOOR - && Build.VERSION.SDK_INT <= BUILD_CODE_CEILING) + return Build.VERSION.SDK_INT <= BUILD_CODE_CEILING && configProvider.getBoolean("assisted_dialing_enabled", false); } |