Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit e43f70af authored by Grace Jia's avatar Grace Jia Committed by Gerrit Code Review
Browse files

Merge "Add new API for new feature of display name."

parents ac674f3b cc16b040
Loading
Loading
Loading
Loading
+2 −0
Original line number Diff line number Diff line
@@ -33870,6 +33870,7 @@ package android.provider {
    field public static final int PRESENTATION_ALLOWED = 1; // 0x1
    field public static final int PRESENTATION_PAYPHONE = 4; // 0x4
    field public static final int PRESENTATION_RESTRICTED = 2; // 0x2
    field public static final int PRESENTATION_UNAVAILABLE = 5; // 0x5
    field public static final int PRESENTATION_UNKNOWN = 3; // 0x3
    field public static final String PRIORITY = "priority";
    field public static final int PRIORITY_NORMAL = 0; // 0x0
@@ -40594,6 +40595,7 @@ package android.telecom {
    field public static final int PRESENTATION_ALLOWED = 1; // 0x1
    field public static final int PRESENTATION_PAYPHONE = 4; // 0x4
    field public static final int PRESENTATION_RESTRICTED = 2; // 0x2
    field public static final int PRESENTATION_UNAVAILABLE = 5; // 0x5
    field public static final int PRESENTATION_UNKNOWN = 3; // 0x3
    field public static final int PRIORITY_NORMAL = 0; // 0x0
    field public static final int PRIORITY_URGENT = 1; // 0x1
+1 −0
Original line number Diff line number Diff line
@@ -13095,6 +13095,7 @@ package android.telephony.ims {
    field public static final int OIR_PRESENTATION_NOT_RESTRICTED = 2; // 0x2
    field public static final int OIR_PRESENTATION_PAYPHONE = 4; // 0x4
    field public static final int OIR_PRESENTATION_RESTRICTED = 1; // 0x1
    field public static final int OIR_PRESENTATION_UNAVAILABLE = 5; // 0x5
    field public static final int OIR_PRESENTATION_UNKNOWN = 3; // 0x3
    field public static final int PRIORITY_NORMAL = 0; // 0x0
    field public static final int PRIORITY_URGENT = 1; // 0x1
+15 −1
Original line number Diff line number Diff line
@@ -231,7 +231,7 @@ public class BlockedNumberContract {
            prefix = { "STATUS_" },
            value = {STATUS_NOT_BLOCKED, STATUS_BLOCKED_IN_LIST, STATUS_BLOCKED_RESTRICTED,
                    STATUS_BLOCKED_UNKNOWN_NUMBER, STATUS_BLOCKED_PAYPHONE,
                    STATUS_BLOCKED_NOT_IN_CONTACTS})
                    STATUS_BLOCKED_NOT_IN_CONTACTS, STATUS_BLOCKED_UNAVAILABLE})
    public @interface BlockStatus {}

    /**
@@ -276,6 +276,13 @@ public class BlockedNumberContract {
     */
    public static final int STATUS_BLOCKED_NOT_IN_CONTACTS = 5;

    /**
     * Integer reason code used with {@link #RES_BLOCK_STATUS} to indicate that a call was blocked
     * because it is from a number not available.
     * @hide
     */
    public static final int STATUS_BLOCKED_UNAVAILABLE = 6;

    /**
     * Integer reason indicating whether a call was blocked, and if so why.
     * @hide
@@ -441,6 +448,9 @@ public class BlockedNumberContract {
        /* Preference key for whether should show an emergency call notification. */
        public static final String ENHANCED_SETTING_KEY_SHOW_EMERGENCY_CALL_NOTIFICATION =
                "show_emergency_call_notification";
        /* Preference key of block unavailable calls setting. */
        public static final String ENHANCED_SETTING_KEY_BLOCK_UNAVAILABLE =
                "block_unavailable_calls_setting";

        /**
         * Notifies the provider that emergency services were contacted by the user.
@@ -547,6 +557,7 @@ public class BlockedNumberContract {
         *        {@link #ENHANCED_SETTING_KEY_BLOCK_PRIVATE}
         *        {@link #ENHANCED_SETTING_KEY_BLOCK_PAYPHONE}
         *        {@link #ENHANCED_SETTING_KEY_BLOCK_UNKNOWN}
         *        {@link #ENHANCED_SETTING_KEY_BLOCK_UNAVAILABLE}
         *        {@link #ENHANCED_SETTING_KEY_EMERGENCY_CALL_NOTIFICATION_SHOWING}
         * @return {@code true} if the setting is enabled. {@code false} otherwise.
         */
@@ -574,6 +585,7 @@ public class BlockedNumberContract {
         *        {@link #ENHANCED_SETTING_KEY_BLOCK_PRIVATE}
         *        {@link #ENHANCED_SETTING_KEY_BLOCK_PAYPHONE}
         *        {@link #ENHANCED_SETTING_KEY_BLOCK_UNKNOWN}
         *        {@link #ENHANCED_SETTING_KEY_BLOCK_UNAVAILABLE}
         *        {@link #ENHANCED_SETTING_KEY_EMERGENCY_CALL_NOTIFICATION_SHOWING}
         * @param value the enabled statue of the setting to set.
         */
@@ -603,6 +615,8 @@ public class BlockedNumberContract {
                    return "blocked - payphone";
                case STATUS_BLOCKED_NOT_IN_CONTACTS:
                    return "blocked - not in contacts";
                case STATUS_BLOCKED_UNAVAILABLE:
                    return "blocked - unavailable";
            }
            return "unknown";
        }
+7 −0
Original line number Diff line number Diff line
@@ -910,6 +910,7 @@ public class CallLog {
         * <li>{@link #PRESENTATION_RESTRICTED}</li>
         * <li>{@link #PRESENTATION_UNKNOWN}</li>
         * <li>{@link #PRESENTATION_PAYPHONE}</li>
         * <li>{@link #PRESENTATION_UNAVAILABLE}</li>
         * </ul>
         * </p>
         *
@@ -925,6 +926,8 @@ public class CallLog {
        public static final int PRESENTATION_UNKNOWN = 3;
        /** Number is a pay phone. */
        public static final int PRESENTATION_PAYPHONE = 4;
        /** Number is unavailable. */
        public static final int PRESENTATION_UNAVAILABLE = 5;

        /**
         * The ISO 3166-1 two letters country code of the country where the
@@ -2028,6 +2031,10 @@ public class CallLog {
                return presentation;
            }

            if (presentation == TelecomManager.PRESENTATION_UNAVAILABLE) {
                return PRESENTATION_UNAVAILABLE;
            }

            if (TextUtils.isEmpty(number)
                    || presentation == TelecomManager.PRESENTATION_UNKNOWN) {
                return PRESENTATION_UNKNOWN;
+3 −2
Original line number Diff line number Diff line
@@ -632,8 +632,9 @@ public abstract class CallScreeningService extends Service {
     * post-dial digits are passed.
     * <p>
     * Calls with a {@link Call.Details#getHandlePresentation()} of
     * {@link TelecomManager#PRESENTATION_RESTRICTED}, {@link TelecomManager#PRESENTATION_UNKNOWN}
     * or {@link TelecomManager#PRESENTATION_PAYPHONE} presentation are not provided to the
     * {@link TelecomManager#PRESENTATION_RESTRICTED}, {@link TelecomManager#PRESENTATION_UNKNOWN},
     * {@link TelecomManager#PRESENTATION_UNAVAILABLE} or
     * {@link TelecomManager#PRESENTATION_PAYPHONE} presentation are not provided to the
     * {@link CallScreeningService}.
     *
     * @param callDetails Information about a new call, see {@link Call.Details}.
Loading