Leaving playback should return to where the viewer was in the channel list #13
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Problem
Stopping playback (Back, or the Beenden button) sets
playerVisible = falseandcurrentChannel = null, and the channel list rebuilds from scratch. Focus lands wherever Compose puts it — typically the first row or the group rail — not on the channel the viewer just watched, and not where they had navigated to in the meantime.Failure scenario
Someone is at channel 221 far down the list, watches it, presses Back — and is dumped at the top of a 505-entry list, having to scroll all the way down again. The same happens after zapping: whatever position was reached is lost the moment playback ends.
Both list panes are affected: the scroll offset of the channel column and the selected entry in the group rail.
Suggested fix
AppState, and restore focus to that row when the list reappearsRelated: the group rail already resets its scroll on every group change (
LaunchedEffect(groupFilter) { scrollToItem(0) }) — the restore path must not fight that.Reported from daily use.
Fixed in
dd612fcand completed in 8068f34; shipped in v0.9.1.AppState.lastWatchedrecords the channel that was opened, so it survives the player closing.LiveScreenlooks that channel up in the currently shown list and, when found, scrolls to it and requests focus on that row — no animation from the top.lastWatchedtoo, so returning lands on the channel actually left from, not the one originally selected.Second half, found in testing: the group rail opens whatever gets focused, so when the player closed and focus landed on "Alle Sender", the view silently switched away from the group being browsed — the list then also appeared "scrolled somewhere". A
restorePendingflag now suppresses the rail's focus-opens-group behaviour until focus has been placed on the remembered channel, so both the group and the position come back.