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

Commit f040254e authored by Andrew Solovay's avatar Andrew Solovay
Browse files

docs: Clarified behavior of legacy apps running on M

Per bug, emphasized that if an app targets SDK 22 or lower, it uses
the install-time permissions model even if it's running on M.
However, also added the note that an M user can *revoke* an app's
permissions after install, which can cause unpredictable behavior.

See first comment for doc stage location.

bug: 25470298
Change-Id: Ia05a1f784595e75bf7b6835dbfdeffcd458f0022
parent 2460971a
Loading
Loading
Loading
Loading
+3 −1
Original line number Diff line number Diff line
@@ -222,7 +222,9 @@ bad user experiences.
  {@link android.Manifest.permission#ACCESS_FINE_LOCATION ACCESS_FINE_LOCATION}
  in its manifest. You should test the app with each of these permissions
  turned on and off, to make sure the app can handle all permission
  configurations gracefully.
  configurations gracefully. Remember, beginning with Android 6.0 the user can
  turn permissions on or off for <em>any</em> app, even an app that targets API
  level 22 or lower.
  </li>

  <li>Use the <a href="{@docRoot}tools/help/adb.html">adb</a> tool to manage
+8 −11
Original line number Diff line number Diff line
@@ -80,13 +80,13 @@ page.metaDescription=Learn about runtime permissions and how they make it easier
</p>

<ul>
  <li>If the device is running Android 5.1 or lower, or your app's target SDK
  <li>If the device is running Android 5.1 or lower, <strong>or</strong> your app's target SDK
  is 22 or lower: If you list a dangerous permission in your manifest, the user
  has to grant the permission when they install the app; if they do not grant
  the permission, the system does not install the app at all.
  </li>

  <li>If the device is running Android 6.0 or higher, and your app's target SDK
  <li>If the device is running Android 6.0 or higher, <strong>and</strong> your app's target SDK
  is 23 or higher: The app has to list the permissions in the manifest,
  <em>and</em> it must request each dangerous permission it needs while the app
  is running. The user can grant or deny each permission, and the app can
@@ -96,14 +96,11 @@ page.metaDescription=Learn about runtime permissions and how they make it easier
</ul>

<p class="note">
  <strong>Note:</strong> This lesson describes how you implement permissions
  requests on apps that target API level
  23 or higher, <em>and</em> are running on a device that's running Android 6.0
  (API level 23) or higher. If the device or the app's
  <a href="{@docRoot}guide/topics/manifest/uses-sdk-element.html#target"
  ><code>targetSdkVersion</code></a>
  is 22 or lower, the system prompts the user to grant all dangerous
  permissions when they install or update the app.
  <strong>Note:</strong> Beginning with Android 6.0 (API level 23), users can
  revoke permissions from any app at any time, even if the app targets a lower
  API level. You should test your app to verify that it behaves properly when
  it's missing a needed permission, regardless of what API level your app
  targets.
</p>

<p>