cordova-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "ASF GitHub Bot (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (CB-13572) resolveLocalFileSystemURL in camera.getPicture not works
Date Sun, 18 Nov 2018 19:43:00 GMT

    [ https://issues.apache.org/jira/browse/CB-13572?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16691014#comment-16691014
] 

ASF GitHub Bot commented on CB-13572:
-------------------------------------

jcesarmobile opened a new issue #273: CB-13572 resolveLocalFileSystemURL in camera.getPicture
not works
URL: https://github.com/apache/cordova-plugin-file/issues/273
 
 
   Cross post of CB-13572
   
   The following url returned from Camera plugin returns Error 5 on Android
     
   ```
   window.resolveLocalFileSystemURL("storage/emulated/0/DCIM/Camera/VID_20180920_161949.mp4",
                 function(entry){
                     console.log("works ok");
                 },
                 function(error){
                     console.log(error);
                 });
   ```

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


> resolveLocalFileSystemURL in camera.getPicture not works
> --------------------------------------------------------
>
>                 Key: CB-13572
>                 URL: https://issues.apache.org/jira/browse/CB-13572
>             Project: Apache Cordova
>          Issue Type: Bug
>          Components: cordova-plugin-camera
>            Reporter: David Gonzalez
>            Priority: Critical
>              Labels: android
>
> This error is only  in Android. In other platforms works succesfully.
> If mediaType is "Camera.MediaType.PICTURE" works ok. The "imageUri" variable is for example:
> content://com.android.providers.media.documents/document/image%3A125 the resolveLocalFileSystemURL
function works ok.
> If mediaType is "Camera.MediaType.VIDEO" or "Camera.MediaType.ALLMEDIA" the "imageUri"
variable is for example:
> /storage/emulated/0/DCIM/Camera/VID_20171114_181057214.mp4 and the resolveLocalFileSystemURL
not works. The response should be file:///storage/emulated/0/DCIM/Camera/VID_20171114_181057214.mp4
> The next code in iOS works correctly and in Android fails.
> {code:javascript}
> navigator.camera.getPicture(
>             function cameraSuccess(imageUri){
>             
>                 console.log(imageUri);
>                 window.resolveLocalFileSystemURL(imageUri,
>                 function(entry){
>                     console.log("works ok");
>                     console.log(entry);
>                 },
>                 function(error){
>                     console.log("error");
>                 });
>         }, function cameraError(error){            
>         }, {
>             destinationType: Camera.DestinationType.FILE_URI,
>             sourceType: Camera.PictureSourceType.PHOTOLIBRARY,
>             mediaType: Camera.MediaType.VIDEO
>         });
> {code}



--
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


Mime
View raw message