Open m-soltys opened 11 months ago
I tested (without PR) on NU7400: the main page updates the state (progress) after a while (refresh timer?). How long should the TV be turned off before the main page is going stale? The app seems to unload after 1 minute.
Forcing an update on resuming is probably fine, but a hard reloading is too much, imo.
The refresh occurs only when the app returns from the 'hidden' state. On my TV (QE75Q60R), this happens only when the TV is turned off with the app in the foreground and then turned back on. The refresh takes no more than a second. Bringing up other windows (settings, home screen) does not trigger this event, nor does it reload the main page.
Any idea what to use instead of hard reloading?
The refresh occurs only when the app returns from the 'hidden' state. On my TV (QE75Q60R), this happens only when the TV is turned off with the app in the foreground and then turned back on. The refresh takes no more than a second. Bringing up other windows (settings, home screen) does not trigger this event, nor does it reload the main page.
Refresh resets focus and scroll. AFAIK, the video player page doesn't support refreshing.
Any idea what to use instead of hard reloading?
Not from the app, but there is a visibility handler in jellyfin-web.
It emits resume
event. Maybe make emby-itemcontainer
refresh on resume
event?
But it will also refresh on window focus :confused: : https://github.com/jellyfin/jellyfin-web/blob/23b3fc44e629f2067097cd460f0fa925987fb353/src/components/apphost.js#L441-L442
Added a visibility change event listener to reload the page when it is brought back from a hidden state. This is useful when the TV is turned off and then turned on, but the application is not killed by the TV. The state of the main page becomes stale, and the latest updates to the video progress are not visible.