cordova-plugin-media-capture icon indicating copy to clipboard operation
cordova-plugin-media-capture copied to clipboard

Prevent audio recording from getting stuck

Open neno-giscloud opened this issue 5 years ago • 5 comments

Swiping away the recording modal on iOS 13 causes the plugin

  • to never stop in the background
  • never to call any callback
  • to prevent you from starting another recording

This commit disables the swiping action.

Platforms affected

iOS

Motivation and Context

This is a temporary fix to avoid https://github.com/apache/cordova-plugin-media-capture/issues/151

Description

Using the isModalInPresentation prop of the UIViewController, I've disable the swiping action.

Testing

This has only been tested on an iOS 13 iPhone 6S. The test was to try and dismiss the recording modal with a swipe. The recording modal was opened by running

navigator.device.capture.captureAudio();

in a javascript console.

Checklist

  • [x] I've run the tests to see all new and existing tests pass
  • [] I added automated test coverage as appropriate for this change
  • [ ] Commit is prefixed with (platform) if this change only applies to one platform (e.g. (android))
  • [x] If this Pull Request resolves an issue, I linked to the issue in the text above (and used the correct keyword to close issues using keywords)
  • [x] I've updated the documentation if necessary

neno-giscloud avatar Oct 24 '19 10:10 neno-giscloud

Hi, when you plan to merge in master?

Thanks

Pazkov avatar Feb 25 '20 15:02 Pazkov

Hi, To echo @Pazkov it would be great to get this merged into master at some point.

StevenConradEllis avatar Mar 16 '20 21:03 StevenConradEllis

I agree with @Pazkov and @StevenConradEllis .

leosbrf avatar Jun 08 '20 14:06 leosbrf

Hi! It is a real problem, march 2021 still not merged, please do it

fess-v avatar Mar 07 '21 19:03 fess-v

Audio modal dismissing is also fixed through PR #186 : better than this one described as a temporary fix?

ath0mas avatar Mar 11 '21 22:03 ath0mas

Resolved by #278 which is a rebase of #186

erisu avatar Aug 09 '23 07:08 erisu