mirror of
https://github.com/samsonjs/media.git
synced 2026-04-27 15:07:40 +00:00
Merge pull request #10776 from dongvanhung:feature/add_support_clear_download_manager_helpers
PiperOrigin-RevId: 491336828
(cherry picked from commit 3581ccde29)
This commit is contained in:
parent
289f0cf00b
commit
3bf99706dc
2 changed files with 13 additions and 0 deletions
|
|
@ -11,6 +11,8 @@
|
||||||
([#10604](https://github.com/google/ExoPlayer/issues/10604)).
|
([#10604](https://github.com/google/ExoPlayer/issues/10604)).
|
||||||
* Add `ExoPlayer.Builder.setPlaybackLooper` that sets a pre-existing
|
* Add `ExoPlayer.Builder.setPlaybackLooper` that sets a pre-existing
|
||||||
playback thread for a new ExoPlayer instance.
|
playback thread for a new ExoPlayer instance.
|
||||||
|
* Allow download manager helpers to be cleared
|
||||||
|
([#10776](https://github.com/google/ExoPlayer/issues/10776)).
|
||||||
* Session:
|
* Session:
|
||||||
* Add helper method to convert platform session token to Media3
|
* Add helper method to convert platform session token to Media3
|
||||||
`SessionToken` ([#171](https://github.com/androidx/media/issues/171)).
|
`SessionToken` ([#171](https://github.com/androidx/media/issues/171)).
|
||||||
|
|
|
||||||
|
|
@ -574,6 +574,17 @@ public abstract class DownloadService extends Service {
|
||||||
Util.startForegroundService(context, intent);
|
Util.startForegroundService(context, intent);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Clear all {@linkplain DownloadManagerHelper download manager helpers} before restarting the
|
||||||
|
* service.
|
||||||
|
*
|
||||||
|
* <p>Calling this method is normally only required if an app supports downloading content for
|
||||||
|
* multiple users for which different download directories should be used.
|
||||||
|
*/
|
||||||
|
public static void clearDownloadManagerHelpers() {
|
||||||
|
downloadManagerHelpers.clear();
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void onCreate() {
|
public void onCreate() {
|
||||||
if (channelId != null) {
|
if (channelId != null) {
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue