fix: subtitles no longer depend on the Settings preference
Verified in the running app: captions render on a downloaded video and on a stream, and the player's menu lists them under SUBTITLES beside AUDIO. Three things were wrong. The preference decided whether subtitles were fetched at all, so "Off" — the old default, which nobody had to choose — silently emptied the subtitle menu as well. Fetching now happens regardless; the preference only says which language switches itself on. Choosing a track from the menu moved the preference from "off" to that language, which re-ran the fetch, tore down the tracks and stalled the stream mid-play. The fetch keys on the language it would ask for, not on the preference, and that value does not change when "off" becomes the language it already stood for. The preference was re-applied on every poll of the track list, so a choice made in the menu was undone a second later. It now applies once per set of tracks, which also makes "Off" mean off. Anyone still carrying the old "off" default is moved to English once. An Off chosen deliberately after this is left alone.
This commit is contained in:
+1
-1
@@ -132,7 +132,7 @@ export const DEFAULT_BULK_LIMIT = 25;
|
||||
export const DEFAULT_SUB_LANG = "en";
|
||||
|
||||
export const SUB_LANGS: Array<{ value: string; label: string }> = [
|
||||
{ value: "off", label: "None" },
|
||||
{ value: "off", label: "Off — pick per video" },
|
||||
{ value: "en", label: "English" },
|
||||
{ value: "nl", label: "Nederlands" },
|
||||
{ value: "de", label: "Deutsch" },
|
||||
|
||||
Reference in New Issue
Block a user