Make SearchWindow manual picks sticky + add 'Reset lyrics for this track' menu item#192
Open
koto9x wants to merge 5 commits into
Open
Make SearchWindow manual picks sticky + add 'Reset lyrics for this track' menu item#192koto9x wants to merge 5 commits into
koto9x wants to merge 5 commits into
Conversation
Lightweight CoreData migration. Adds two fields to SongObject:
- userPicked: Bool (default false) — true when the user manually
selected lyrics via the search window; sticky flag that bypasses
the network chain on subsequent plays.
- sourceProvider: String? — which provider succeeded ("spotify",
"lrclib", "user_picked", etc.); used by the reset button.
…nd cache Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Adds resetLyricsForCurrentTrack() to ViewModel (deletes CoreData entry by track ID, cancels in-flight fetch, re-triggers setCurrentProperties) and wires it to a new arrow.counterclockwise SmallMenubarButton placed between the search (magnifyingglass) and translate buttons. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
…use correct method names - SearchWindow.swift: drop song.appleMusicID + song.albumID (those fields are added by the separate Apple Music PR; this PR only adds userPicked + sourceProvider to the schema) - ViewModel: MediaController() call no longer takes bundleIdentifier param (ejbills/mediaremote-adapter removed it in b8ce5d1); call setCurrentProperties() not setCurrentPropertiesPublic() which doesn't exist upstream
6 tasks
koto9x
added a commit
to koto9x/LyricFever
that referenced
this pull request
Jul 4, 2026
Upstream PRs: - A: koto9x:upstream-pr-a-applemusic → aviwad#191 Title: Add Apple Music as a first-class lyric source via MusicKit Commits: TTMLParser, AppleMusicAuthManager, AppleMusicAuthView, schema v2 (appleMusicID only), catalog ID capture (Task 6), AppleMusicLyricProvider, ViewModel chain reorder, auth sheet trigger + Window scene fix - B: koto9x:upstream-pr-b-sticky-picks → aviwad#192 Title: Make SearchWindow manual picks sticky + add 'Reset lyrics' menu item Commits: schema v2 (userPicked+sourceProvider only), ViewModel sticky read path, SearchWindow apply, resetLyricsForCurrentTrack + menubar button - C: koto9x:upstream-pr-c-album-prefetch → aviwad#193 Title: Optional: prefetch lyrics for every track on the currently-playing album Commits: schema v3 (albumID), AppleMusicPrefetcher.warmAlbum, prefetchAlbumLyrics toggle (DEFAULT OFF), ViewModel gating Adapter dependency: ejbills/mediaremote-adapter#4 (koto9x/mediaremote-adapter feat/expose-adam-ids temporarily pinned in PR-A pbxproj until upstream merges). Stays in fork (not upstreamed): Lyrics9x provider, 3-tier romanization+translation, Plexamp player + smart routing, MediaRemote adapter callback fork-specific bits, Tailscale ATS exception, warmQueueWindow, sandbox fix for Plexamp, Kotopia Inc team/bundle ID. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Two universal UX improvements that are independent of any Apple Music or player-specific work:
Sticky manual picks: When the user opens the search window (magnifying glass) and applies a specific lyric source, that choice is now persisted with
userPicked = true. On subsequent plays of the same track, LyricFever skips the entire network chain and returns the cached lyrics directly — no unnecessary re-fetching.Reset button: A new
arrow.counterclockwiseicon in the menubar button row lets the user bust the sticky cache for the currently-playing track. LyricFever deletes the CoreData entry and re-runs the full lyric chain on next play. Useful when lyrics were auto-cached incorrectly and then manually fixed, or after a new release updates official sync.What's included
SongObjectschema v2 — adds two fields via lightweight Core Data migration:userPicked: Bool(defaultfalse) — true when lyrics came from a user's explicit search-window selectionsourceProvider: String?— which provider succeeded ("spotify","lrclib","user_picked", etc.)SearchWindow.swift— setsuserPicked = trueandsourceProvider = "user_picked"when user applies lyricsViewModel.resetLyricsForCurrentTrack()— deletes the CoreData entry by track ID, cancels in-flight fetch, and re-triggerssetCurrentProperties()MenubarWindowView.swift— newarrow.counterclockwiseSmallMenubarButtonwired to the reset method; tooltip: "Reset lyrics for this track (clears cache, re-runs chain)"ViewModel.fetchAllNetworkLyrics()— writessourceProvideron every successful chain result anduserPicked = falseViewModel.fetchLyrics()— sticky fast-path: if existing CoreData entry hasuserPicked = true, return immediately without hitting the networkWhat's NOT included (intentional)
userPicked+sourceProviderNote on
MediaController()fixThe upstream repo's
ViewModel.swiftstill callsMediaController(bundleIdentifier:), butejbills/mediaremote-adapterremoved that parameter in commitb8ce5d1. This PR quietly fixes that call toMediaController()so the upstream builds cleanly.Test plan
userPickedremainsfalsein CoreDataarrow.counterclockwisereset button → CoreData entry deleted → replay → full chain fires again