Prevents playbutton in files episode list from changing back to pause on upnext #1627
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
When playing a local file, on completion, the play button would breifly get set to played, but then would change back to a pause button when the player switched to the podcast episode up next in the queue.
This issue only seemed to occur when going from a user episode to a podcast episode. If the episode up next was also a user episode, the playbutton didn't get switched back to a pause button.
The fix I've implemented works, however it doesn't solve the root of the problem which is that the playback state of the user episode gets set back to playing after it's marked as completed. My hypothesis is that whatever is updating the playback state of the upnext episode to playing is doing the same to the played local file.
I'm happy to look into this further to try and solve the issue this bug is stemming from, but I would need some guidance and direction on how player events and episode switching works as I wasn't able to quite figure it out.
Fixes #397
Testing Instructions
Checklist
./gradlew spotlessApply
to automatically apply formatting/linting)modules/services/localization/src/main/res/values/strings.xml
I have tested any UI changes...