OSDN Git Service

Rename READ_PHONE_NUMBER to READ_PHONE_NUMBERS
authorChad Brubaker <cbrubaker@google.com>
Thu, 30 Mar 2017 23:29:10 +0000 (16:29 -0700)
committerChad Brubaker <cbrubaker@google.com>
Fri, 31 Mar 2017 18:20:02 +0000 (11:20 -0700)
Bug: 35853790
Test: make -j128 checkbuild
Test: cts-tradefed run commandAndExit cts-dev -m CtsPermission2TestCases
Change-Id: I11d374cbbb6c2deaf74ac784ff995bd182fe9157

api/current.txt
api/system-current.txt
api/test-current.txt
core/java/android/app/AppOpsManager.java
core/res/AndroidManifest.xml
core/res/res/values/strings.xml
proto/src/metrics_constants.proto
services/core/java/com/android/server/pm/PackageManagerService.java
telephony/java/android/telephony/TelephonyManager.java

index 344ad62..248d3a6 100644 (file)
@@ -104,7 +104,7 @@ package android {
     field public static final java.lang.String READ_FRAME_BUFFER = "android.permission.READ_FRAME_BUFFER";
     field public static final deprecated java.lang.String READ_INPUT_STATE = "android.permission.READ_INPUT_STATE";
     field public static final java.lang.String READ_LOGS = "android.permission.READ_LOGS";
-    field public static final java.lang.String READ_PHONE_NUMBER = "android.permission.READ_PHONE_NUMBER";
+    field public static final java.lang.String READ_PHONE_NUMBERS = "android.permission.READ_PHONE_NUMBERS";
     field public static final java.lang.String READ_PHONE_STATE = "android.permission.READ_PHONE_STATE";
     field public static final java.lang.String READ_SMS = "android.permission.READ_SMS";
     field public static final java.lang.String READ_SYNC_SETTINGS = "android.permission.READ_SYNC_SETTINGS";
@@ -4180,7 +4180,7 @@ package android.app {
     field public static final java.lang.String OPSTR_READ_CELL_BROADCASTS = "android:read_cell_broadcasts";
     field public static final java.lang.String OPSTR_READ_CONTACTS = "android:read_contacts";
     field public static final java.lang.String OPSTR_READ_EXTERNAL_STORAGE = "android:read_external_storage";
-    field public static final java.lang.String OPSTR_READ_PHONE_NUMBER = "android:read_phone_number";
+    field public static final java.lang.String OPSTR_READ_PHONE_NUMBERS = "android:read_phone_numbers";
     field public static final java.lang.String OPSTR_READ_PHONE_STATE = "android:read_phone_state";
     field public static final java.lang.String OPSTR_READ_SMS = "android:read_sms";
     field public static final java.lang.String OPSTR_RECEIVE_MMS = "android:receive_mms";
@@ -46003,7 +46003,6 @@ package android.view {
     method public static deprecated int getEdgeSlop();
     method public static deprecated int getFadingEdgeLength();
     method public static deprecated long getGlobalActionKeyTimeout();
-    method public float getScaledHorizontalScrollFactor();
     method public static int getJumpTapTimeout();
     method public static int getKeyRepeatDelay();
     method public static int getKeyRepeatTimeout();
@@ -46015,6 +46014,7 @@ package android.view {
     method public int getScaledDoubleTapSlop();
     method public int getScaledEdgeSlop();
     method public int getScaledFadingEdgeLength();
+    method public float getScaledHorizontalScrollFactor();
     method public int getScaledMaximumDrawingCacheSize();
     method public int getScaledMaximumFlingVelocity();
     method public int getScaledMinimumFlingVelocity();
@@ -46023,6 +46023,7 @@ package android.view {
     method public int getScaledPagingTouchSlop();
     method public int getScaledScrollBarSize();
     method public int getScaledTouchSlop();
+    method public float getScaledVerticalScrollFactor();
     method public int getScaledWindowTouchSlop();
     method public static int getScrollBarFadeDuration();
     method public static deprecated int getScrollBarSize();
@@ -46030,7 +46031,6 @@ package android.view {
     method public static float getScrollFriction();
     method public static int getTapTimeout();
     method public static deprecated int getTouchSlop();
-    method public float getScaledVerticalScrollFactor();
     method public static deprecated int getWindowTouchSlop();
     method public static long getZoomControlsTimeout();
     method public boolean hasPermanentMenuKey();
index 9a605b7..83bd4df 100644 (file)
@@ -182,7 +182,7 @@ package android {
     field public static final java.lang.String READ_LOGS = "android.permission.READ_LOGS";
     field public static final java.lang.String READ_NETWORK_USAGE_HISTORY = "android.permission.READ_NETWORK_USAGE_HISTORY";
     field public static final java.lang.String READ_OEM_UNLOCK_STATE = "android.permission.READ_OEM_UNLOCK_STATE";
-    field public static final java.lang.String READ_PHONE_NUMBER = "android.permission.READ_PHONE_NUMBER";
+    field public static final java.lang.String READ_PHONE_NUMBERS = "android.permission.READ_PHONE_NUMBERS";
     field public static final java.lang.String READ_PHONE_STATE = "android.permission.READ_PHONE_STATE";
     field public static final java.lang.String READ_PRIVILEGED_PHONE_STATE = "android.permission.READ_PRIVILEGED_PHONE_STATE";
     field public static final java.lang.String READ_SEARCH_INDEXABLES = "android.permission.READ_SEARCH_INDEXABLES";
@@ -4325,7 +4325,7 @@ package android.app {
     field public static final java.lang.String OPSTR_READ_CELL_BROADCASTS = "android:read_cell_broadcasts";
     field public static final java.lang.String OPSTR_READ_CONTACTS = "android:read_contacts";
     field public static final java.lang.String OPSTR_READ_EXTERNAL_STORAGE = "android:read_external_storage";
-    field public static final java.lang.String OPSTR_READ_PHONE_NUMBER = "android:read_phone_number";
+    field public static final java.lang.String OPSTR_READ_PHONE_NUMBERS = "android:read_phone_numbers";
     field public static final java.lang.String OPSTR_READ_PHONE_STATE = "android:read_phone_state";
     field public static final java.lang.String OPSTR_READ_SMS = "android:read_sms";
     field public static final java.lang.String OPSTR_RECEIVE_MMS = "android:receive_mms";
@@ -49460,7 +49460,6 @@ package android.view {
     method public static deprecated int getEdgeSlop();
     method public static deprecated int getFadingEdgeLength();
     method public static deprecated long getGlobalActionKeyTimeout();
-    method public float getScaledHorizontalScrollFactor();
     method public static int getJumpTapTimeout();
     method public static int getKeyRepeatDelay();
     method public static int getKeyRepeatTimeout();
@@ -49472,6 +49471,7 @@ package android.view {
     method public int getScaledDoubleTapSlop();
     method public int getScaledEdgeSlop();
     method public int getScaledFadingEdgeLength();
+    method public float getScaledHorizontalScrollFactor();
     method public int getScaledMaximumDrawingCacheSize();
     method public int getScaledMaximumFlingVelocity();
     method public int getScaledMinimumFlingVelocity();
@@ -49480,6 +49480,7 @@ package android.view {
     method public int getScaledPagingTouchSlop();
     method public int getScaledScrollBarSize();
     method public int getScaledTouchSlop();
+    method public float getScaledVerticalScrollFactor();
     method public int getScaledWindowTouchSlop();
     method public static int getScrollBarFadeDuration();
     method public static deprecated int getScrollBarSize();
@@ -49487,7 +49488,6 @@ package android.view {
     method public static float getScrollFriction();
     method public static int getTapTimeout();
     method public static deprecated int getTouchSlop();
-    method public float getScaledVerticalScrollFactor();
     method public static deprecated int getWindowTouchSlop();
     method public static long getZoomControlsTimeout();
     method public boolean hasPermanentMenuKey();
index a5c9867..939a94a 100644 (file)
@@ -104,7 +104,7 @@ package android {
     field public static final java.lang.String READ_FRAME_BUFFER = "android.permission.READ_FRAME_BUFFER";
     field public static final deprecated java.lang.String READ_INPUT_STATE = "android.permission.READ_INPUT_STATE";
     field public static final java.lang.String READ_LOGS = "android.permission.READ_LOGS";
-    field public static final java.lang.String READ_PHONE_NUMBER = "android.permission.READ_PHONE_NUMBER";
+    field public static final java.lang.String READ_PHONE_NUMBERS = "android.permission.READ_PHONE_NUMBERS";
     field public static final java.lang.String READ_PHONE_STATE = "android.permission.READ_PHONE_STATE";
     field public static final java.lang.String READ_SMS = "android.permission.READ_SMS";
     field public static final java.lang.String READ_SYNC_SETTINGS = "android.permission.READ_SYNC_SETTINGS";
@@ -4192,7 +4192,7 @@ package android.app {
     field public static final java.lang.String OPSTR_READ_CELL_BROADCASTS = "android:read_cell_broadcasts";
     field public static final java.lang.String OPSTR_READ_CONTACTS = "android:read_contacts";
     field public static final java.lang.String OPSTR_READ_EXTERNAL_STORAGE = "android:read_external_storage";
-    field public static final java.lang.String OPSTR_READ_PHONE_NUMBER = "android:read_phone_number";
+    field public static final java.lang.String OPSTR_READ_PHONE_NUMBERS = "android:read_phone_numbers";
     field public static final java.lang.String OPSTR_READ_PHONE_STATE = "android:read_phone_state";
     field public static final java.lang.String OPSTR_READ_SMS = "android:read_sms";
     field public static final java.lang.String OPSTR_RECEIVE_MMS = "android:receive_mms";
@@ -46380,7 +46380,6 @@ package android.view {
     method public static deprecated int getEdgeSlop();
     method public static deprecated int getFadingEdgeLength();
     method public static deprecated long getGlobalActionKeyTimeout();
-    method public float getScaledHorizontalScrollFactor();
     method public static int getHoverTooltipHideShortTimeout();
     method public static int getHoverTooltipHideTimeout();
     method public static int getHoverTooltipShowTimeout();
@@ -46396,6 +46395,7 @@ package android.view {
     method public int getScaledDoubleTapSlop();
     method public int getScaledEdgeSlop();
     method public int getScaledFadingEdgeLength();
+    method public float getScaledHorizontalScrollFactor();
     method public int getScaledMaximumDrawingCacheSize();
     method public int getScaledMaximumFlingVelocity();
     method public int getScaledMinimumFlingVelocity();
@@ -46404,6 +46404,7 @@ package android.view {
     method public int getScaledPagingTouchSlop();
     method public int getScaledScrollBarSize();
     method public int getScaledTouchSlop();
+    method public float getScaledVerticalScrollFactor();
     method public int getScaledWindowTouchSlop();
     method public static int getScrollBarFadeDuration();
     method public static deprecated int getScrollBarSize();
@@ -46411,7 +46412,6 @@ package android.view {
     method public static float getScrollFriction();
     method public static int getTapTimeout();
     method public static deprecated int getTouchSlop();
-    method public float getScaledVerticalScrollFactor();
     method public static deprecated int getWindowTouchSlop();
     method public static long getZoomControlsTimeout();
     method public boolean hasPermanentMenuKey();
index cbd7b9d..8292152 100644 (file)
@@ -242,7 +242,7 @@ public class AppOpsManager {
     /** @hide */
     public static final int OP_AUDIO_ACCESSIBILITY_VOLUME = 64;
     /** @hide Read the phone number. */
-    public static final int OP_READ_PHONE_NUMBER = 65;
+    public static final int OP_READ_PHONE_NUMBERS = 65;
     /** @hide Request package installs through package installer */
     public static final int OP_REQUEST_INSTALL_PACKAGES = 66;
     /** @hide Enter picture-in-picture. */
@@ -353,8 +353,8 @@ public class AppOpsManager {
     /** @hide Get device accounts. */
     public static final String OPSTR_GET_ACCOUNTS
             = "android:get_accounts";
-    public static final String OPSTR_READ_PHONE_NUMBER
-            = "android:read_phone_number";
+    public static final String OPSTR_READ_PHONE_NUMBERS
+            = "android:read_phone_numbers";
     /** Access to picture-in-picture. */
     public static final String OPSTR_PICTURE_IN_PICTURE
             = "android:picture_in_picture";
@@ -391,7 +391,7 @@ public class AppOpsManager {
             OP_FINE_LOCATION,
             // Phone
             OP_READ_PHONE_STATE,
-            OP_READ_PHONE_NUMBER,
+            OP_READ_PHONE_NUMBERS,
             OP_CALL_PHONE,
             OP_READ_CALL_LOG,
             OP_WRITE_CALL_LOG,
@@ -487,7 +487,7 @@ public class AppOpsManager {
             OP_GET_ACCOUNTS,
             OP_RUN_IN_BACKGROUND,
             OP_AUDIO_ACCESSIBILITY_VOLUME,
-            OP_READ_PHONE_NUMBER,
+            OP_READ_PHONE_NUMBERS,
             OP_REQUEST_INSTALL_PACKAGES,
             OP_PICTURE_IN_PICTURE,
             OP_INSTANT_APP_START_FOREGROUND,
@@ -564,7 +564,7 @@ public class AppOpsManager {
             OPSTR_GET_ACCOUNTS,
             null,
             null, // OP_AUDIO_ACCESSIBILITY_VOLUME
-            OPSTR_READ_PHONE_NUMBER,
+            OPSTR_READ_PHONE_NUMBERS,
             null, // OP_REQUEST_INSTALL_PACKAGES
             OPSTR_PICTURE_IN_PICTURE,
             OPSTR_INSTANT_APP_START_FOREGROUND,
@@ -641,7 +641,7 @@ public class AppOpsManager {
             "GET_ACCOUNTS",
             "RUN_IN_BACKGROUND",
             "AUDIO_ACCESSIBILITY_VOLUME",
-            "READ_PHONE_NUMBER",
+            "READ_PHONE_NUMBERS",
             "REQUEST_INSTALL_PACKAGES",
             "PICTURE_IN_PICTURE",
             "INSTANT_APP_START_FOREGROUND",
@@ -718,7 +718,7 @@ public class AppOpsManager {
             Manifest.permission.GET_ACCOUNTS,
             null, // no permission for running in background
             null, // no permission for changing accessibility volume
-            Manifest.permission.READ_PHONE_NUMBER,
+            Manifest.permission.READ_PHONE_NUMBERS,
             Manifest.permission.REQUEST_INSTALL_PACKAGES,
             null, // no permission for entering picture-in-picture on hide
             Manifest.permission.INSTANT_APP_FOREGROUND_SERVICE,
@@ -796,7 +796,7 @@ public class AppOpsManager {
             null, // GET_ACCOUNTS
             null, // RUN_IN_BACKGROUND
             UserManager.DISALLOW_ADJUST_VOLUME, //AUDIO_ACCESSIBILITY_VOLUME
-            null, // READ_PHONE_NUMBER
+            null, // READ_PHONE_NUMBERS
             null, // REQUEST_INSTALL_PACKAGES
             null, // ENTER_PICTURE_IN_PICTURE_ON_HIDE
             null, // INSTANT_APP_START_FOREGROUND
@@ -873,7 +873,7 @@ public class AppOpsManager {
             false, // GET_ACCOUNTS
             false, // RUN_IN_BACKGROUND
             false, // AUDIO_ACCESSIBILITY_VOLUME
-            false, // READ_PHONE_NUMBER
+            false, // READ_PHONE_NUMBERS
             false, // REQUEST_INSTALL_PACKAGES
             false, // ENTER_PICTURE_IN_PICTURE_ON_HIDE
             false, // INSTANT_APP_START_FOREGROUND
index 362794e..ffcb847 100644 (file)
         android:description="@string/permdesc_readPhoneState"
         android:protectionLevel="dangerous" />
 
-    <!-- Allows read access to the device's phone number. This is a subset of the capabilities
+    <!-- Allows read access to the device's phone number(s). This is a subset of the capabilities
          granted by {@link #READ_PHONE_STATE} but is exposed to ephemeral applications.
          <p>Protection level: dangerous-->
-    <permission android:name="android.permission.READ_PHONE_NUMBER"
+    <permission android:name="android.permission.READ_PHONE_NUMBERS"
         android:permissionGroup="android.permission-group.PHONE"
         android:label="@string/permlab_readPhoneNumber"
-        android:description="@string/permdesc_readPhoneNumber"
+        android:description="@string/permdesc_readPhoneNumbers"
         android:protectionLevel="dangerous|ephemeral" />
 
     <!-- Allows an application to initiate a phone call without going through
index 4afa8dc..131c6c4 100644 (file)
         order to improve the calling experience.</string>
 
     <!-- Title of an application permission, listed so the user can choose whether they want to allow the application to do this. -->
-    <string name="permlab_readPhoneNumber">read phone number</string>
+    <string name="permlab_readPhoneNumbers">read phone numbers</string>
     <!-- Description of an application permission, listed so the user can choose whether they want to allow the application to do this. -->
-    <string name="permdesc_readPhoneNumber">Allows the app to access the phone number of the device.</string>
+    <string name="permdesc_readPhoneNumbers">Allows the app to access the phone numbers of the device.</string>
 
     <!-- Title of an application permission, listed so the user can choose whether they want to allow the application to do this. -->
     <string name="permlab_wakeLock" product="tablet">prevent tablet from sleeping</string>
index da441f5..78bc01d 100644 (file)
@@ -3188,21 +3188,21 @@ message MetricsEvent {
     // ACTION: Logged when a provisioning session has completed
     PROVISIONING_SESSION_COMPLETED = 735;
 
-    // ACTION: An app requested the permission READ_PHONE_NUMBER
+    // ACTION: An app requested the permission READ_PHONE_NUMBERS
     // PACKAGE: The package name of the app requesting the permission
-    ACTION_PERMISSION_REQUEST_READ_PHONE_NUMBER = 736;
+    ACTION_PERMISSION_REQUEST_READ_PHONE_NUMBERS = 736;
 
-    // ACTION: An app was granted the permission READ_PHONE_NUMBER
+    // ACTION: An app was granted the permission READ_PHONE_NUMBERS
     // PACKAGE: The package name of the app that was granted the permission
-    ACTION_PERMISSION_GRANT_READ_PHONE_NUMBER = 737;
+    ACTION_PERMISSION_GRANT_READ_PHONE_NUMBERS = 737;
 
-    // ACTION: An app requested the permission READ_PHONE_NUMBER and the request was denied
+    // ACTION: An app requested the permission READ_PHONE_NUMBERS and the request was denied
     // PACKAGE: The package name of the app requesting the permission
-    ACTION_PERMISSION_DENIED_READ_PHONE_NUMBER = 738;
+    ACTION_PERMISSION_DENIED_READ_PHONE_NUMBERS = 738;
 
-    // ACTION: The permission READ_PHONE_NUMBER was revoked for an app
+    // ACTION: The permission READ_PHONE_NUMBERS was revoked for an app
     // PACKAGE: The package name of the app the permission was revoked for
-    ACTION_PERMISSION_REVOKE_READ_PHONE_NUMBER = 739;
+    ACTION_PERMISSION_REVOKE_READ_PHONE_NUMBERS = 739;
 
     // ACTION: QS Brightness Slider (with auto brightness disabled, and VR enabled)
     //   SUBTYPE: slider value
index 2115f31..ddb6d5f 100644 (file)
@@ -568,7 +568,7 @@ public class PackageManagerService extends IPackageManager.Stub {
             Manifest.permission.RECEIVE_MMS,
             Manifest.permission.READ_EXTERNAL_STORAGE,
             Manifest.permission.WRITE_EXTERNAL_STORAGE,
-            Manifest.permission.READ_PHONE_NUMBER,
+            Manifest.permission.READ_PHONE_NUMBERS,
             Manifest.permission.ANSWER_PHONE_CALLS);
 
 
index 26c9430..061c0af 100644 (file)
@@ -2395,7 +2395,7 @@ public class TelephonyManager {
      *   OR
      *   {@link android.Manifest.permission#READ_SMS}
      *   OR
-     *   {@link android.Manifest.permission#READ_PHONE_NUMBER}
+     *   {@link android.Manifest.permission#READ_PHONE_NUMBERS}
      * <p>
      * The default SMS app can also use this.
      */
@@ -2412,7 +2412,7 @@ public class TelephonyManager {
      *   OR
      *   {@link android.Manifest.permission#READ_SMS}
      *   OR
-     *   {@link android.Manifest.permission#READ_PHONE_NUMBER}
+     *   {@link android.Manifest.permission#READ_PHONE_NUMBERS}
      * <p>
      * The default SMS app can also use this.
      *