diff --git a/CHANGELOG.md b/CHANGELOG.md index 2270307..6d6aa49 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,9 @@ # Kaleido releases +## 0.3.1 + +- Fix episode pages getting stuck on Resume after scrolling the season row away from the original episode, returning Home, and reopening it from Continue Watching. + ## 0.3.0 - Add Categories alongside Discover and Library in Movies and TV Shows. Browse the genres from the selected Plex library, with movies and shows kept separate. diff --git a/app/src/main/java/tv/kaleido/app/BrowseScreens.kt b/app/src/main/java/tv/kaleido/app/BrowseScreens.kt index ee3962a..4d59c8f 100644 --- a/app/src/main/java/tv/kaleido/app/BrowseScreens.kt +++ b/app/src/main/java/tv/kaleido/app/BrowseScreens.kt @@ -108,6 +108,9 @@ import androidx.compose.ui.text.input.TextFieldValue val initial=remember(rowId){items.indexOfFirst{it.id==initialItem}.coerceAtLeast(0)} val entry=items.indexOfFirst{it.id==selectedItem}.takeIf{it>=0} ?: initial val row=rememberLazyListState(initialFirstVisibleItemIndex=(initial-1).coerceAtLeast(0)) + // A reopened episode page resets its selection, but its saved scroll can still + // point elsewhere. Compose the entry card before the header sends focus Down. + LaunchedEffect(rowId){if(initialItem!=null)row.scrollToItem((initial-1).coerceAtLeast(0))} Column { Box(Modifier.padding(horizontal=Cinema.gutter)){SectionHeading(title,subtitle)} LazyRow(state=row,contentPadding=PaddingValues(start=Cinema.gutter,end=Cinema.gutter,top=5.dp,bottom=5.dp),horizontalArrangement=Arrangement.spacedBy(if(landscape)13.dp else 12.dp),modifier=Modifier.focusRestorer(fallback=entryFocus ?: FocusRequester.Default)) { diff --git a/distribution/Kaleido.apk b/distribution/Kaleido.apk index 817ea24..84afadb 100644 Binary files a/distribution/Kaleido.apk and b/distribution/Kaleido.apk differ diff --git a/distribution/Kaleido.apk.sha256 b/distribution/Kaleido.apk.sha256 index 19017d2..88788d9 100644 --- a/distribution/Kaleido.apk.sha256 +++ b/distribution/Kaleido.apk.sha256 @@ -1 +1 @@ -38c998fbd09f410828deb30882196e722d209e411d6ddb10067265668d740d55 Kaleido.apk +0270206e1a3cf1574f58cd8f5f8bcef828277012bf2a56cf082a556656c6f3a1 Kaleido.apk diff --git a/distribution/latest.json b/distribution/latest.json index d07389f..419011b 100644 --- a/distribution/latest.json +++ b/distribution/latest.json @@ -1,7 +1,7 @@ { - "version": "0.3.0", - "versionCode": 15, - "url": "https://git.elijahkuntz.com/Elijah/Kaleido/raw/tag/v0.3.0/distribution/Kaleido.apk", - "checksumUrl": "https://git.elijahkuntz.com/Elijah/Kaleido/raw/tag/v0.3.0/distribution/Kaleido.apk.sha256", - "notes": "- Add Categories alongside Discover and Library in Movies and TV Shows. Browse the genres from the selected Plex library, with movies and shows kept separate.\n- Add a light grey A\u2013Z jump bar on the right of libraries and category results. Jump to letters with the remote, including titles beyond the first loaded page, and press Left to enter the titles.\n- Put exact title matches first in Search, including the Silo series ahead of unrelated movie matches. Order result rows by relevance instead of always placing movies first.\n- Add optional Plex theme music on movie, series, season and episode pages, with a separate volume setting. Music stops for playback and when Kaleido leaves the foreground; titles without theme tracks stay silent.\n- Add an optional app-wide volume boost from +3 to +12 dB for all video playback. Boost uses decoded audio instead of compressed passthrough; Off preserves the original audio path.\n- Remove repeated category headings in Settings and restore focus to preference controls after closing their dialogs." + "version": "0.3.1", + "versionCode": 16, + "url": "https://git.elijahkuntz.com/Elijah/Kaleido/raw/tag/v0.3.1/distribution/Kaleido.apk", + "checksumUrl": "https://git.elijahkuntz.com/Elijah/Kaleido/raw/tag/v0.3.1/distribution/Kaleido.apk.sha256", + "notes": "- Fix episode pages getting stuck on Resume after scrolling the season row away from the original episode, returning Home, and reopening it from Continue Watching." } diff --git a/scripts/verify_episode_row_reentry.py b/scripts/verify_episode_row_reentry.py new file mode 100644 index 0000000..fafd25a --- /dev/null +++ b/scripts/verify_episode_row_reentry.py @@ -0,0 +1,19 @@ +"""Reproduce only the Continue Watching episode-row reentry focus regression.""" +from device import screenshot +from verify_ui import launch,key,snapshot,focus,focused,labels,wait + +launch();key(20,2) +for _ in range(20): + if 'Hazbin Hotel' in focus(snapshot()):break + key(22) +else:raise AssertionError('Hazbin Hotel fixture is missing from Continue Watching') +focused('S1 · E7');key(23);focused('Resume from') +key(20);focused('7. Hello Rosie!') +key(21,7);focused('1. Overture') +assert '7. Hello Rosie!' not in labels(snapshot()),'Episode 7 must be offscreen before leaving' +key(4);focused('Hazbin Hotel');key(23);focused('Resume from') +wait(lambda r:'7. Hello Rosie!' in labels(r),'Reopened row reveals the entry episode') +key(20);focused('7. Hello Rosie!') +screenshot('episode-row-reentry-031') +print('PASS Home → Hazbin S1E7 → episode 1 → Back → reopen → Down focuses episode 7',flush=True) +key(4);focused('Hazbin Hotel');key(4);focused('Home') diff --git a/version.properties b/version.properties index 77a2edf..48722fc 100644 --- a/version.properties +++ b/version.properties @@ -1,2 +1,2 @@ -versionName=0.3.0 -versionCode=15 +versionName=0.3.1 +versionCode=16