e-picsa / picsa-apps

Monorepo for building tools to support E-PICSA Apps
https://picsa.app
GNU General Public License v3.0
6 stars 2 forks source link

bug(android) - farmer activity video playback resume #219

Closed chrismclarke closed 7 months ago

chrismclarke commented 8 months ago

Is your feature request related to a problem? Please describe. When running on web, farmer activity videos play inside a web browser and users can toggle between video and other tabs freely, resuming the video from where they left off whenever the return (example below)

Web - videos resume correctly

PICSA (3).webm

However when running on native android device the video opens in a full-screen player, and once exiting loses progress. When trying to replay sometime it will not even load the video, and other times it restarts from the beginning. Ideally the native android version should be able to resume playback in the same way the web player does.

Android - videos do not resume

untitled (1).webm

Describe the solution you'd like We want to keep full-screen functionality, so ideally somehow hooking into playback events to manually track the time video is paused and automatically resuming from that time in the component

Additional context Code for the video player can be found in libs\shared\src\features\video-player. It uses native plugin capacitor-video-player

Running the app on a local android device or emulator for debugging is a bit tricky, however some documentation has been added to https://docs.picsa.app/advanced/testing to try and help organise a good developer workflow (reach out if having issues).