You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@cordova.apache.org by "jcesarmobile (JIRA)" <ji...@apache.org> on 2018/09/21 23:55:00 UTC
[jira] [Closed] (CB-10207) CaptureAudio - Support for Android
Marshmallow
[ https://issues.apache.org/jira/browse/CB-10207?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
jcesarmobile closed CB-10207.
-----------------------------
Resolution: Cannot Reproduce
I can't reproduce with latest version.
Try with latest version and if you still face the problem, create a new issue on github https://github.com/apache/cordova-plugin-media-capture/issues
> CaptureAudio - Support for Android Marshmallow
> ----------------------------------------------
>
> Key: CB-10207
> URL: https://issues.apache.org/jira/browse/CB-10207
> Project: Apache Cordova
> Issue Type: Bug
> Components: cordova-plugin-media-capture
> Reporter: Paulo Victor Maluf
> Priority: Major
> Labels: android, features, patch, triaged
>
> By calling the captureAudio on Android Marshmallow(6.0) the audio recorder is not opened.
> My code:
> {code}
> $scope.captureAudio = function() {
> var options = { limit: 1, duration: 10 };
> console.log("captureAudio");
> $cordovaCapture.captureAudio(options).then(function(mediaFiles) {
> console.log("Success! Audio data is here");
> var i, path, name, mime, len;
> for (i = 0, len = mediaFiles.length; i < len; i += 1) {
> path = mediaFiles[i].fullPath;
> name = mediaFiles[i].name;
> mime = mediaFiles[i].type;
> console.log("Loop: " + i + " Path: " + path + " Name: " + name + " Mime: " + mime);
> }
> },
> function(err){
> switch (err) {
> case CaptureError.CAPTURE_NO_MEDIA_FILES:
> navigator.notification.alert('no media files', null);
> console.log('no media files');
> break;
> case CaptureError.CAPTURE_INTERNAL_ERR:
> navigator.notification.alert('internal err', null);
> console.log('internal err');
> break;
> case CaptureError.CAPTURE_INVALID_ARGUMENT:
> navigator.notification.alert('invalid arg', null);
> console.log('invalid arg');
> break;
> case CaptureError.CAPTURE_NOT_SUPPORTED:
> navigator.notification.alert('not supported', null);
> console.log('not supported');
> break;
> }
> });
> };
> {code}
> The same code works fine on Android Lollipop(5.0).
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@cordova.apache.org
For additional commands, e-mail: issues-help@cordova.apache.org