mirror of
https://github.com/samsonjs/media.git
synced 2026-03-29 10:05:48 +00:00
Document that DownloadService needs notification permissions
Starting with Android 13 (API 33) an app needs to request the
permission to post notifications or notifications are suppressed.
This change documents this in the class level JavaDoc of the
`DownloadService`.
Issue: google/ExoPlayer#10884
PiperOrigin-RevId: 501346908
(cherry picked from commit 20aa5bd926)
This commit is contained in:
parent
1b8608f179
commit
2c088269c6
1 changed files with 10 additions and 1 deletions
|
|
@ -40,7 +40,16 @@ import java.util.List;
|
|||
import org.checkerframework.checker.nullness.qual.MonotonicNonNull;
|
||||
import org.checkerframework.checker.nullness.qual.RequiresNonNull;
|
||||
|
||||
/** A {@link Service} for downloading media. */
|
||||
/**
|
||||
* A {@link Service} for downloading media.
|
||||
*
|
||||
* <p>Apps with target SDK 33 and greater need to add the {@code
|
||||
* android.permission.POST_NOTIFICATIONS} permission to the manifest and request the permission at
|
||||
* runtime before starting downloads. Without that permission granted by the user, notifications
|
||||
* posted by this service are not displayed. See <a
|
||||
* href="https://developer.android.com/develop/ui/views/notifications/notification-permission">the
|
||||
* official UI guide</a> for more detailed information.
|
||||
*/
|
||||
@UnstableApi
|
||||
public abstract class DownloadService extends Service {
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue