feat: Stream Now instant-play of a random track from the nav button
This commit is contained in:
@@ -63,6 +63,17 @@ public interface IStreamingPlayerService : IPlayerService
|
||||
// Streaming control methods
|
||||
Task SelectTrackStreaming(TrackDto track);
|
||||
|
||||
/// <summary>
|
||||
/// Initializes the player (if needed) and resumes the AudioContext. Call this synchronously at
|
||||
/// the very start of a user-gesture handler — before any <c>await</c> on network I/O — so the
|
||||
/// gesture is still "active" when the context resumes. Safari refuses to start a suspended
|
||||
/// AudioContext once the originating gesture has been consumed by an intervening await
|
||||
/// (e.g. fetching which track to play), so warming here and streaming after is load-bearing.
|
||||
/// <see cref="SelectTrackStreaming"/> also resumes the context, but only after its own internal
|
||||
/// awaits — too late for a handler that must first fetch the track to play.
|
||||
/// </summary>
|
||||
Task WarmAudioContext();
|
||||
|
||||
/// <summary>
|
||||
/// Stages a track as the current track without touching the audio context or starting the
|
||||
/// stream. Used by the embed player, where there is no user gesture on initial load: the track
|
||||
|
||||
Reference in New Issue
Block a user