You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Note to self: there is a slight lag between the time an event is broadcast from the platform side and the time it is received on the flutter side, which may create surprises for flutter-side state processing. For example, after await setUrl(...) completes on the flutter side, the state transition to stopped may lag slightly, and for a brief moment querying player.playbackState may still report connecting.
At some point, this code should be improved so that events are categorised into flutter-side initiated events which should update on the flutter side immediately, and asynchronous events which originate on the platform side, such as when buffering is detected, and for which the lag is not a problem.
The text was updated successfully, but these errors were encountered:
For example, after await setUrl(...) completes on the flutter side, the state transition to stopped may lag slightly, and for a brief moment querying player.playbackState may still report connecting.
Yes! I dealt with this exact issue. I ended up using playbackStateStream, and taking the first value which wasn't connecting
This issue has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs, or use StackOverflow if you need help with just_audio.
Note to self: there is a slight lag between the time an event is broadcast from the platform side and the time it is received on the flutter side, which may create surprises for flutter-side state processing. For example, after
await setUrl(...)
completes on the flutter side, the state transition tostopped
may lag slightly, and for a brief moment queryingplayer.playbackState
may still reportconnecting
.At some point, this code should be improved so that events are categorised into flutter-side initiated events which should update on the flutter side immediately, and asynchronous events which originate on the platform side, such as when buffering is detected, and for which the lag is not a problem.
The text was updated successfully, but these errors were encountered: