SDKLauncher-Android icon indicating copy to clipboard operation
SDKLauncher-Android copied to clipboard

If media overlay is playing, audio doesn't stop when app is backgrounded or device is turned off

Open msintov opened this issue 9 years ago • 2 comments

There is a bug where media overlay audio doesn't stop playing when the app is backgrounded or the device is turned off.

Repro steps:

  1. Launch SDKLaunder-Android
  2. Open a book with a media overlay
  3. Play the media overlay
  4. Background the app or touch the power button to turn off the display

Actual results: audio continues playing Expected results: audio stops

One potential fix is to call ReadiumSDK.reader.toggleMediaOverlay() if the media overlay is playing in WebViewActivity.onPause(). Seems to work.

msintov avatar May 08 '15 18:05 msintov

The proposed solution sounds good. Please note that the Readium native application "launchers" are minimalistic by design, so there may be a number of other user experience / device integration issues.

danielweck avatar May 10 '15 20:05 danielweck

Finally created a pull request for this here: https://github.com/readium/SDKLauncher-Android/pull/74

msintov avatar Oct 02 '15 19:10 msintov