fix(session): save full queue with all tracks and metadata

The save was broken in two ways:
1. Only current_track + upcoming (capped at 20) were saved, dropping
   all history tracks. Queue was reconstructed incomplete on restore.
2. Track metadata (hires, bit_depth, sample_rate, source, etc.) was
   not being persisted, only the basic 6 fields.

Add v2_get_all_queue_tracks command that returns the full uncapped
track list with correct current_index. Use it in saveSessionBeforeClose
instead of the capped v2_get_queue_state. Map all metadata fields.
This commit is contained in:
vicrodh committed 2026-02-20 20:33:39 -06:00
1 parent 5a0d4c50a1
commit aa1aa32f7a
6 files changed
+45 -27

No files matched your search

+1
View File
@@ -932,6 +932,7 @@ pub fn run() {
commands_v2::v2_set_force_x11,
commands_v2::v2_restart_app,
commands_v2::v2_get_queue_state,
commands_v2::v2_get_all_queue_tracks,
commands_v2::v2_get_current_queue_track,
commands_v2::v2_set_repeat_mode,
commands_v2::v2_toggle_shuffle,