From 9ec8d6dafcee6c9722672eefad28ee3aeba4feb9 Mon Sep 17 00:00:00 2001 From: jacqueline Date: Wed, 28 Aug 2024 12:45:10 +1000 Subject: Handle the loading state whilst appending many tracks better 1) Update the queue length periodically so that the user can see we're working 2) Clear any previous track and display "loading..." instead --- src/tangara/audio/audio_fsm.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'src/tangara/audio/audio_fsm.cpp') diff --git a/src/tangara/audio/audio_fsm.cpp b/src/tangara/audio/audio_fsm.cpp index 54ea5b6c..163e56ec 100644 --- a/src/tangara/audio/audio_fsm.cpp +++ b/src/tangara/audio/audio_fsm.cpp @@ -112,10 +112,13 @@ void AudioState::react(const QueueUpdate& ev) { cmd.new_track = std::monostate{}; } break; + case QueueUpdate::kBulkLoadingUpdate: + // Bulk loading updates are informational only; a separate QueueUpdate + // event will be sent when loading is done. case QueueUpdate::kDeserialised: - default: // The current track is deserialised separately in order to retain seek // position. + default: return; } -- cgit v1.2.3