1. Pull up all subclasses of DownloadAction into DownloadAction
2. Add DownloaderFactory for Downloader instantiation, and DefaultDownloaderFactory
to replace the instantiation logic being removed from the DownloadAction
subclasses.
This change will upgrade existing action files gracefully (i.e. it does not
lose compatibility with the existing offline implementation, other than some
minor breaking changes to the API).
TODOs:
1. Move test methods from the XDownloadActionTest classes into DownloadActionTest.
This will be done in a subsequent CL. There's a lot of consolidation that can
be done here, including de-duplicating some of the test code added in this CL.
2. Look at merging DownloaderConstructorHelper into DefaultDownloaderFactory.
3. Use customCacheKey in DASH/HLS/SS Downloaders, for completeness.
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=222258983
Copybara propagates this bit on the files, so removing it avoids some
unnecessary changes in the first migrated commit.
Also losslessly optimize two PNG files.
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=220268951
Currently there is no way to disable (or reduce) the logcat output generated
by ExoPlayer.
Issue:#4665
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=213421072
- Add @Deprecated on overrides of deprecated method.
- Suppress deprecation warnings where appropriate.
- Use non-deprecated alternatives where appropriate.
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=210092434
Apps targeting P or later now must request this permission in order to
use foreground services.
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=209762160
The options menu is not available on Android TV, which triggers a
null pointer exception whenever a sample is chosen.
This CL is a temporary fix until we rework the UI to not use
an options menu.
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=209742076
Add a demo app that shows case how to use APIs from MetadataRetriever to
retriever track groups and frames from some media.
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=207269221
This is needed for implementing (optional) support for audio focus handling in a
later change.
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=206899837
Using this surface it's possible to play 360 videos in a non-VR Activity that is
affected by phone and touch input.
RELNOTES=true
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=205720776
As the manifest and media data sources can be the same now, we can provide
a simplified constructor with just one data source factory.
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=205658046
This simplifies the player setup and prevents using deprecated methods in the demo.
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=205642981
Also moved shared code to SegmentDownloadAction between its subclasses.
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=202294880
The DefaultEventListener was added for selective overrides. Now that Java 8
support is enabled, these selective listener overrides can be implemented
more easily and more flexible using default methods.
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=201695490
This happens when the device screen is locked.
This fixes a previous attempt to fix the problem.
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=199130325
The ACCESS_NETWORK_STATE permission is only included indirectly which doesn't
work in all build systems.
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=197399274
This type of flicker was visible (at least on my S8) whenever starting
the demo app process (from being properly killed) when other notifications
(e.g. completed download notification) was present.
This change passes whether the service was started as foreground through
the intent, and only applies the show-notification-on-stop hack if it
was. It's only necessary to start as foreground if your app is not already
in the foreground, so it's not necessary to do this from activity/ui
components.
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=195594930
If an app wants to reconcile its own state with that of a DownloadManager,
it's helpful to know when the DownloadManager has finished restoring any
previously persisted tasks.
Also suppress initial "state changed to paused" listener invocations for
tasks that are immediately started.
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=195594881
Also convert them to exposing periods and track groups, like
regular MediaSources do. This gets us much closer to being
able to use standard track selection components during offline
initialization. The helper is responsible for reverse mapping
selected tracks onto physical streams when generating the
download action. This is trivial except for the HLS case, which
is a TODO for now.
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=195500826
This may be preferable for using custom binary data,
and it's still easy to store Strings if needed.
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=195486817