feat(smartplaylist): materialize on creation and show track counts
Smart playlists now evaluate and snapshot their rules at creation time instead of only lazily on first open, so the playlist list can show a real track count in place of the "Smart" label. A one-time idempotent startup sweep backfills snapshots for smart playlists created before creation-time materialization existed. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
@@ -202,6 +202,9 @@ func (yj *YellowJacketApp) OnStartup(ctx context.Context) {
|
||||
yj.playlist.EnsureDefaultPlaylist()
|
||||
// Recover playlists that lost tracks from a pre-fix FullRescan.
|
||||
go yj.playlist.RepopulateFromM3U()
|
||||
// Backfill snapshots for smart playlists created before
|
||||
// creation-time materialization existed.
|
||||
go yj.playlist.MaterializeUnmaterializedSmartPlaylists()
|
||||
|
||||
// Initialize speaker hardware (player struct created in
|
||||
// NewYellowJacketApp for Wails binding registration).
|
||||
|
||||
Reference in New Issue
Block a user