This format is not supported by ExoPlayer when returned as HLS streams, so we
can't play streams using this format and this delivery method.
Also improve the Javadoc of ListHelper.getPlayableStreams.
This behavior was present before 0.24.0 and the player UI separation and
avoided crashes for which their exception contained
"Context.startForegroundService() did not then call Service.startForeground()".
Some player nullability checks have been also added, and the player service is
now stopped when it has been started from a media button and there is nothing
to play.
As the player can be null in some cases, we have to make sure that the player
is not null, by using Optionals on the player itself instead of its methods
returning Optionals.
If the player is null, the play queue audio track menu will now be hidden.
As the fragment context can be null in some cases, we have to make sure that
the context is not null before calling
DeviceUtils.hasAnimationsAnimatorDurationEnabled.
If the context is null, the button will now not be hidden automatically.
- Currently, only a list of videos separated by newline are added in
the share content.
- This makes it difficult to identify a specific video in a list of
Urls.
- Used string resources for the sharing content formats.
- Added a confirmation dialog for users to choose between sharing
playlist formats.
- Added Playlist name as the header and corresponding video name for
each video url in following format.
Playlist
- Music1: https://media-url1
- Music2: https://media-url2
- Music3: https://media-url3
Co-authored-by: TobiGr <tobigr@users.noreply.github.com>
Instead of searching for the first audio stream matching a compatible media
format, this change makes SecondaryStreamHelper.getAudioStreamFor use methods
isLimitingDataUsage, getAudioFormatComparator and getAudioIndexByHighestRank of
ListHelper to get an audio stream which can be muxed into a video-only stream,
if available.
This allows users to download videos with the highest audio quality available
if no resolution limit on mobile data usage has been set.
The order of formats used to search a compatible audio stream has been kept.
Do not restore last opened license after a rotation change when the license was closed earlier.
This commit adds onCancelListener and onDismissListener to the AlertDialogs which are used to display the licenses.
imageListToDbUrl should be used if the URL is going to be saved to the database, to avoid saving nothing in case at the moment of saving the user preference is to not show images.
Add the separate utility class PlayButtonHelper to handle the initialization of the listeners.
The ClickListeners on playlist controls had different behaviours. This commit fixes that.
The commit also refactors the way how the app determines whether it is started for the first time. The previous version was not clean and recent in this PR caused it to fail.