funkwhale-app-android/app/src/main/java/audio/funkwhale/ffa
Hugh Daschbach d734953b54
Replace deprecated SimpleExoPlayer with ExoPlayer.
This is part of an effort to resolve deprecation warnings.

Most of this is simple refactoring of interfaces that change between
the two Player implementations.  There are a few other changes that
deserve further explanation.

Testing indicated that the play/pause button was being reset to pause
in MainActivity:refreshCurrentTrack.  In the past this was likely
masked by the ordering of other callbacks.  We have removed the
nowPlayingToggle.icon update from MainActivity, leaving that UI update
to PlayerService.

One of the bigger refactorings in PlayerService was forced by the
deprecation of Player.EventListener.onPlayerStateChanged.  That forced
separation of handling playWhenReady and playbackState transitions.
In the SimpleExoPlayer implementations, where these transitions were
combined, the module attempted to work out playing state from a
combination of these two state variables.

In addition to separating the reaction to these state changes, we have
added a listener to onIsPlayingChanged, eliminating the need for some
of the earlier logic in Player.EventListener.onPlayerStateChanged.
This addition, along with the separation of state transition
processing, seems to provide a simpler implementation.  But it is,
certainly, a possible source of bugs.
2022-12-06 09:35:33 +01:00
..
activities Replace deprecated SimpleExoPlayer with ExoPlayer. 2022-12-06 09:35:33 +01:00
adapters Resolve warning: FragmentPagerAdapter deprecated. 2022-12-06 09:35:32 +01:00
fragments Resolve warning: FragmentPagerAdapter deprecated. 2022-12-06 09:35:32 +01:00
koin Resolve warning: ExoDatabaseProvider deprecated. 2022-12-06 09:35:32 +01:00
model Fix existing linting problems 2021-09-09 09:56:15 +02:00
playback Replace deprecated SimpleExoPlayer with ExoPlayer. 2022-12-06 09:35:33 +01:00
repositories Minor cleanup: consistent deserialization. 2022-09-03 11:09:21 +00:00
utils LoginActivity: startActivityForResult deprecated. 2022-12-06 09:35:33 +01:00
views Housekeeping/migrate to viewbinding 2021-07-16 08:03:52 +00:00
FFA.kt RequentBus: replace deprecated implementation. 2022-12-06 09:35:32 +01:00