[jira] [Commented] (CB-9490) LG G4 camera application saves photos when using destinationType DATA_URL

2016-07-20 Thread ASF GitHub Bot (JIRA)

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

ASF GitHub Bot commented on CB-9490:


Github user cojomojo closed the pull request at:

https://github.com/apache/cordova-plugin-camera/pull/115


> LG G4 camera application saves photos when using destinationType DATA_URL
> -
>
> Key: CB-9490
> URL: https://issues.apache.org/jira/browse/CB-9490
> Project: Apache Cordova
>  Issue Type: Bug
>  Components: Plugin Camera
> Environment: LG G4, Android 5.1
>Reporter: Cody Balos
>Assignee: Cody Balos
>Priority: Minor
>  Labels: Android, triaged
>  Time Spent: 6h
>  Remaining Estimate: 0h
>
> So far this issue only happens on an LG G4 using the stock camera application:
> Using the camera plugin, with destinationType set to DATA_URL,
> the expected functionality is for the base64 string to be returned to the 
> javascript interface, and not saved to the file system without explicitly 
> saving it separately. Using the LG G4 stock camera application, all photos 
> are saved even when using destinationType DATA_URL if the retake option is 
> used. 
> The issue does not occur when using the Google Camera application or Camera 
> 360 (both on the Play Store). 



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

-
To unsubscribe, e-mail: issues-unsubscr...@cordova.apache.org
For additional commands, e-mail: issues-h...@cordova.apache.org



[jira] [Commented] (CB-9490) LG G4 camera application saves photos when using destinationType DATA_URL

2016-03-26 Thread ASF GitHub Bot (JIRA)

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

ASF GitHub Bot commented on CB-9490:


Github user cojomojo commented on the pull request:


https://github.com/apache/cordova-plugin-camera/pull/115#issuecomment-201945371
  
@infil00p Should we close this PR? After thinking about this for quite some 
time, I think fixing https://issues.apache.org/jira/browse/CB-9506 would be 
favorable over this and would by consequence make this PR irrelevant anyways.


> LG G4 camera application saves photos when using destinationType DATA_URL
> -
>
> Key: CB-9490
> URL: https://issues.apache.org/jira/browse/CB-9490
> Project: Apache Cordova
>  Issue Type: Bug
>  Components: Plugin Camera
> Environment: LG G4, Android 5.1
>Reporter: Cody Balos
>Assignee: Cody Balos
>Priority: Minor
>  Labels: Android, triaged
>  Time Spent: 6h
>  Remaining Estimate: 0h
>
> So far this issue only happens on an LG G4 using the stock camera application:
> Using the camera plugin, with destinationType set to DATA_URL,
> the expected functionality is for the base64 string to be returned to the 
> javascript interface, and not saved to the file system without explicitly 
> saving it separately. Using the LG G4 stock camera application, all photos 
> are saved even when using destinationType DATA_URL if the retake option is 
> used. 
> The issue does not occur when using the Google Camera application or Camera 
> 360 (both on the Play Store). 



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

-
To unsubscribe, e-mail: issues-unsubscr...@cordova.apache.org
For additional commands, e-mail: issues-h...@cordova.apache.org



[jira] [Commented] (CB-9490) LG G4 camera application saves photos when using destinationType DATA_URL

2015-10-23 Thread ASF GitHub Bot (JIRA)

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

ASF GitHub Bot commented on CB-9490:


Github user cojomojo commented on the pull request:


https://github.com/apache/cordova-plugin-camera/pull/115#issuecomment-150748364
  
@infil00p Yes, it would still have the problem. I submitted this fix still 
because it is trivial (this PR won't change how the plugin is used at all, and 
only changes 2 lines, outside of the function itself), while the fix for 9506 
will be non-trivial.  Therefore, I think that unless 9506 is going to be fixed 
soon we should still patch 9490 with this. 


> LG G4 camera application saves photos when using destinationType DATA_URL
> -
>
> Key: CB-9490
> URL: https://issues.apache.org/jira/browse/CB-9490
> Project: Apache Cordova
>  Issue Type: Bug
>  Components: Plugin Camera
> Environment: LG G4, Android 5.1
>Reporter: Cody Balos
>Assignee: Cody Balos
>  Labels: Android
>  Time Spent: 6h
>  Remaining Estimate: 0h
>
> So far this issue only happens on an LG G4 using the stock camera application:
> Using the camera plugin, with destinationType set to DATA_URL,
> the expected functionality is for the base64 string to be returned to the 
> javascript interface, and not saved to the file system without explicitly 
> saving it separately. Using the LG G4 stock camera application, all photos 
> are saved even when using destinationType DATA_URL if the retake option is 
> used. 
> The issue does not occur when using the Google Camera application or Camera 
> 360 (both on the Play Store). 



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

-
To unsubscribe, e-mail: issues-unsubscr...@cordova.apache.org
For additional commands, e-mail: issues-h...@cordova.apache.org



[jira] [Commented] (CB-9490) LG G4 camera application saves photos when using destinationType DATA_URL

2015-10-23 Thread ASF GitHub Bot (JIRA)

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

ASF GitHub Bot commented on CB-9490:


Github user infil00p commented on the pull request:


https://github.com/apache/cordova-plugin-camera/pull/115#issuecomment-150703173
  
@cojomojo Won't this still have the problem you found when you filed this? 
https://issues.apache.org/jira/browse/CB-9506


> LG G4 camera application saves photos when using destinationType DATA_URL
> -
>
> Key: CB-9490
> URL: https://issues.apache.org/jira/browse/CB-9490
> Project: Apache Cordova
>  Issue Type: Bug
>  Components: Plugin Camera
> Environment: LG G4, Android 5.1
>Reporter: Cody Balos
>Assignee: Cody Balos
>  Time Spent: 6h
>  Remaining Estimate: 0h
>
> So far this issue only happens on an LG G4 using the stock camera application:
> Using the camera plugin, with destinationType set to DATA_URL,
> the expected functionality is for the base64 string to be returned to the 
> javascript interface, and not saved to the file system without explicitly 
> saving it separately. Using the LG G4 stock camera application, all photos 
> are saved even when using destinationType DATA_URL if the retake option is 
> used. 
> The issue does not occur when using the Google Camera application or Camera 
> 360 (both on the Play Store). 



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

-
To unsubscribe, e-mail: issues-unsubscr...@cordova.apache.org
For additional commands, e-mail: issues-h...@cordova.apache.org



[jira] [Commented] (CB-9490) LG G4 camera application saves photos when using destinationType DATA_URL

2015-10-23 Thread Joe Bowser (JIRA)

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

Joe Bowser commented on CB-9490:


This seems related to CB-9506.  How do we reconcile the two, and can we?

> LG G4 camera application saves photos when using destinationType DATA_URL
> -
>
> Key: CB-9490
> URL: https://issues.apache.org/jira/browse/CB-9490
> Project: Apache Cordova
>  Issue Type: Bug
>  Components: Plugin Camera
> Environment: LG G4, Android 5.1
>Reporter: Cody Balos
>Assignee: Cody Balos
>  Labels: Android
>  Time Spent: 6h
>  Remaining Estimate: 0h
>
> So far this issue only happens on an LG G4 using the stock camera application:
> Using the camera plugin, with destinationType set to DATA_URL,
> the expected functionality is for the base64 string to be returned to the 
> javascript interface, and not saved to the file system without explicitly 
> saving it separately. Using the LG G4 stock camera application, all photos 
> are saved even when using destinationType DATA_URL if the retake option is 
> used. 
> The issue does not occur when using the Google Camera application or Camera 
> 360 (both on the Play Store). 



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

-
To unsubscribe, e-mail: issues-unsubscr...@cordova.apache.org
For additional commands, e-mail: issues-h...@cordova.apache.org



[jira] [Commented] (CB-9490) LG G4 camera application saves photos when using destinationType DATA_URL

2015-10-12 Thread ASF GitHub Bot (JIRA)

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

ASF GitHub Bot commented on CB-9490:


Github user sgrebnov commented on a diff in the pull request:


https://github.com/apache/cordova-plugin-camera/pull/115#discussion_r41742092
  
--- Diff: src/android/CameraLauncher.java ---
@@ -241,6 +241,7 @@ public void takePicture(int returnType, int 
encodingType) {
  * @return a File object pointing to the temporary picture
  */
 private File createCaptureFile(int encodingType) {
+File photo = null;
--- End diff --

Looks like this variable is not used


> LG G4 camera application saves photos when using destinationType DATA_URL
> -
>
> Key: CB-9490
> URL: https://issues.apache.org/jira/browse/CB-9490
> Project: Apache Cordova
>  Issue Type: Bug
>  Components: Plugin Camera
> Environment: LG G4, Android 5.1
>Reporter: Cody Balos
>Assignee: Cody Balos
>  Time Spent: 6h
>  Remaining Estimate: 0h
>
> So far this issue only happens on an LG G4 using the stock camera application:
> Using the camera plugin, with destinationType set to DATA_URL,
> the expected functionality is for the base64 string to be returned to the 
> javascript interface, and not saved to the file system without explicitly 
> saving it separately. Using the LG G4 stock camera application, all photos 
> are saved even when using destinationType DATA_URL if the retake option is 
> used. 
> The issue does not occur when using the Google Camera application or Camera 
> 360 (both on the Play Store). 



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

-
To unsubscribe, e-mail: issues-unsubscr...@cordova.apache.org
For additional commands, e-mail: issues-h...@cordova.apache.org



[jira] [Commented] (CB-9490) LG G4 camera application saves photos when using destinationType DATA_URL

2015-10-12 Thread ASF GitHub Bot (JIRA)

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

ASF GitHub Bot commented on CB-9490:


Github user sgrebnov commented on a diff in the pull request:


https://github.com/apache/cordova-plugin-camera/pull/115#discussion_r41742198
  
--- Diff: src/android/CameraLauncher.java ---
@@ -386,12 +387,10 @@ private void processResultFromCamera(int destType, 
Intent intent) throws IOExcep
 FileHelper.stripFileProtocol(this.croppedUri.toString()) :
 FileHelper.stripFileProtocol(this.imageUri.toString());
 
-if (this.encodingType == JPEG) {
-try {
-//We don't support PNG, so let's not pretend we do
-exif.createInFile(sourcePath);
-exif.readExifData();
-rotate = exif.getOrientation();
+//We don't support PNG, so let's not pretend we do
--- End diff --

I don't think this change should be in scope of this PR (I know there is a 
person working on .PNG support so this will just bring merge conflict) 


> LG G4 camera application saves photos when using destinationType DATA_URL
> -
>
> Key: CB-9490
> URL: https://issues.apache.org/jira/browse/CB-9490
> Project: Apache Cordova
>  Issue Type: Bug
>  Components: Plugin Camera
> Environment: LG G4, Android 5.1
>Reporter: Cody Balos
>Assignee: Cody Balos
>  Time Spent: 6h
>  Remaining Estimate: 0h
>
> So far this issue only happens on an LG G4 using the stock camera application:
> Using the camera plugin, with destinationType set to DATA_URL,
> the expected functionality is for the base64 string to be returned to the 
> javascript interface, and not saved to the file system without explicitly 
> saving it separately. Using the LG G4 stock camera application, all photos 
> are saved even when using destinationType DATA_URL if the retake option is 
> used. 
> The issue does not occur when using the Google Camera application or Camera 
> 360 (both on the Play Store). 



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

-
To unsubscribe, e-mail: issues-unsubscr...@cordova.apache.org
For additional commands, e-mail: issues-h...@cordova.apache.org



[jira] [Commented] (CB-9490) LG G4 camera application saves photos when using destinationType DATA_URL

2015-10-12 Thread ASF GitHub Bot (JIRA)

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

ASF GitHub Bot commented on CB-9490:


Github user sgrebnov commented on the pull request:


https://github.com/apache/cordova-plugin-camera/pull/115#issuecomment-147357893
  
Reviewed: :+1: thank you @cojomojo!
@vladimir-kotikov, I know that you are working on some other improvements 
so please merge this along with your work! 


> LG G4 camera application saves photos when using destinationType DATA_URL
> -
>
> Key: CB-9490
> URL: https://issues.apache.org/jira/browse/CB-9490
> Project: Apache Cordova
>  Issue Type: Bug
>  Components: Plugin Camera
> Environment: LG G4, Android 5.1
>Reporter: Cody Balos
>Assignee: Cody Balos
>  Time Spent: 6h
>  Remaining Estimate: 0h
>
> So far this issue only happens on an LG G4 using the stock camera application:
> Using the camera plugin, with destinationType set to DATA_URL,
> the expected functionality is for the base64 string to be returned to the 
> javascript interface, and not saved to the file system without explicitly 
> saving it separately. Using the LG G4 stock camera application, all photos 
> are saved even when using destinationType DATA_URL if the retake option is 
> used. 
> The issue does not occur when using the Google Camera application or Camera 
> 360 (both on the Play Store). 



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

-
To unsubscribe, e-mail: issues-unsubscr...@cordova.apache.org
For additional commands, e-mail: issues-h...@cordova.apache.org



[jira] [Commented] (CB-9490) LG G4 camera application saves photos when using destinationType DATA_URL

2015-10-12 Thread ASF GitHub Bot (JIRA)

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

ASF GitHub Bot commented on CB-9490:


Github user infil00p commented on the pull request:


https://github.com/apache/cordova-plugin-camera/pull/115#issuecomment-147443002
  
Can this wait until after my Cordova-Android 5.0.x pull request is merged 
in? checkForDuplicateImage requires a permission on Android 6.0+ and I want to 
make sure that we don't accidentally add something without a permissions check.


> LG G4 camera application saves photos when using destinationType DATA_URL
> -
>
> Key: CB-9490
> URL: https://issues.apache.org/jira/browse/CB-9490
> Project: Apache Cordova
>  Issue Type: Bug
>  Components: Plugin Camera
> Environment: LG G4, Android 5.1
>Reporter: Cody Balos
>Assignee: Cody Balos
>  Time Spent: 6h
>  Remaining Estimate: 0h
>
> So far this issue only happens on an LG G4 using the stock camera application:
> Using the camera plugin, with destinationType set to DATA_URL,
> the expected functionality is for the base64 string to be returned to the 
> javascript interface, and not saved to the file system without explicitly 
> saving it separately. Using the LG G4 stock camera application, all photos 
> are saved even when using destinationType DATA_URL if the retake option is 
> used. 
> The issue does not occur when using the Google Camera application or Camera 
> 360 (both on the Play Store). 



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

-
To unsubscribe, e-mail: issues-unsubscr...@cordova.apache.org
For additional commands, e-mail: issues-h...@cordova.apache.org



[jira] [Commented] (CB-9490) LG G4 camera application saves photos when using destinationType DATA_URL

2015-10-12 Thread ASF GitHub Bot (JIRA)

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

ASF GitHub Bot commented on CB-9490:


Github user cojomojo commented on the pull request:


https://github.com/apache/cordova-plugin-camera/pull/115#issuecomment-147434553
  
@sgrebnov Something got messed up when I merged in the latest before 
resubmitting. I doubt this is even valid Java right now, I'll fix it later 
today and then we should be good to go. 


> LG G4 camera application saves photos when using destinationType DATA_URL
> -
>
> Key: CB-9490
> URL: https://issues.apache.org/jira/browse/CB-9490
> Project: Apache Cordova
>  Issue Type: Bug
>  Components: Plugin Camera
> Environment: LG G4, Android 5.1
>Reporter: Cody Balos
>Assignee: Cody Balos
>  Time Spent: 6h
>  Remaining Estimate: 0h
>
> So far this issue only happens on an LG G4 using the stock camera application:
> Using the camera plugin, with destinationType set to DATA_URL,
> the expected functionality is for the base64 string to be returned to the 
> javascript interface, and not saved to the file system without explicitly 
> saving it separately. Using the LG G4 stock camera application, all photos 
> are saved even when using destinationType DATA_URL if the retake option is 
> used. 
> The issue does not occur when using the Google Camera application or Camera 
> 360 (both on the Play Store). 



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

-
To unsubscribe, e-mail: issues-unsubscr...@cordova.apache.org
For additional commands, e-mail: issues-h...@cordova.apache.org



[jira] [Commented] (CB-9490) LG G4 camera application saves photos when using destinationType DATA_URL

2015-10-12 Thread ASF GitHub Bot (JIRA)

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

ASF GitHub Bot commented on CB-9490:


Github user cojomojo commented on the pull request:


https://github.com/apache/cordova-plugin-camera/pull/115#issuecomment-147443350
  
@infil00p Good idea, let me know when it's merged


> LG G4 camera application saves photos when using destinationType DATA_URL
> -
>
> Key: CB-9490
> URL: https://issues.apache.org/jira/browse/CB-9490
> Project: Apache Cordova
>  Issue Type: Bug
>  Components: Plugin Camera
> Environment: LG G4, Android 5.1
>Reporter: Cody Balos
>Assignee: Cody Balos
>  Time Spent: 6h
>  Remaining Estimate: 0h
>
> So far this issue only happens on an LG G4 using the stock camera application:
> Using the camera plugin, with destinationType set to DATA_URL,
> the expected functionality is for the base64 string to be returned to the 
> javascript interface, and not saved to the file system without explicitly 
> saving it separately. Using the LG G4 stock camera application, all photos 
> are saved even when using destinationType DATA_URL if the retake option is 
> used. 
> The issue does not occur when using the Google Camera application or Camera 
> 360 (both on the Play Store). 



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

-
To unsubscribe, e-mail: issues-unsubscr...@cordova.apache.org
For additional commands, e-mail: issues-h...@cordova.apache.org



[jira] [Commented] (CB-9490) LG G4 camera application saves photos when using destinationType DATA_URL

2015-10-12 Thread ASF GitHub Bot (JIRA)

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

ASF GitHub Bot commented on CB-9490:


Github user cojomojo commented on the pull request:


https://github.com/apache/cordova-plugin-camera/pull/115#issuecomment-147473478
  
@sgrebnov @vladimir-kotikov OK, I fixed the issue caused by a bad merge. 
This PR is ready once we see how @infil00p 's PR for Cordova-Android 5.0.x  and 
the permissions issue he mentioned affects things.


> LG G4 camera application saves photos when using destinationType DATA_URL
> -
>
> Key: CB-9490
> URL: https://issues.apache.org/jira/browse/CB-9490
> Project: Apache Cordova
>  Issue Type: Bug
>  Components: Plugin Camera
> Environment: LG G4, Android 5.1
>Reporter: Cody Balos
>Assignee: Cody Balos
>  Time Spent: 6h
>  Remaining Estimate: 0h
>
> So far this issue only happens on an LG G4 using the stock camera application:
> Using the camera plugin, with destinationType set to DATA_URL,
> the expected functionality is for the base64 string to be returned to the 
> javascript interface, and not saved to the file system without explicitly 
> saving it separately. Using the LG G4 stock camera application, all photos 
> are saved even when using destinationType DATA_URL if the retake option is 
> used. 
> The issue does not occur when using the Google Camera application or Camera 
> 360 (both on the Play Store). 



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

-
To unsubscribe, e-mail: issues-unsubscr...@cordova.apache.org
For additional commands, e-mail: issues-h...@cordova.apache.org



[jira] [Commented] (CB-9490) LG G4 camera application saves photos when using destinationType DATA_URL

2015-10-10 Thread ASF GitHub Bot (JIRA)

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

ASF GitHub Bot commented on CB-9490:


Github user cojomojo commented on the pull request:


https://github.com/apache/cordova-plugin-camera/pull/115#issuecomment-147061485
  
@sgrebnov Ok, I finally got around to doing what you suggested. Please 
re-review.


> LG G4 camera application saves photos when using destinationType DATA_URL
> -
>
> Key: CB-9490
> URL: https://issues.apache.org/jira/browse/CB-9490
> Project: Apache Cordova
>  Issue Type: Bug
>  Components: Plugin Camera
> Environment: LG G4, Android 5.1
>Reporter: Cody Balos
>Assignee: Cody Balos
>  Time Spent: 6h
>  Remaining Estimate: 0h
>
> So far this issue only happens on an LG G4 using the stock camera application:
> Using the camera plugin, with destinationType set to DATA_URL,
> the expected functionality is for the base64 string to be returned to the 
> javascript interface, and not saved to the file system without explicitly 
> saving it separately. Using the LG G4 stock camera application, all photos 
> are saved even when using destinationType DATA_URL if the retake option is 
> used. 
> The issue does not occur when using the Google Camera application or Camera 
> 360 (both on the Play Store). 



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

-
To unsubscribe, e-mail: issues-unsubscr...@cordova.apache.org
For additional commands, e-mail: issues-h...@cordova.apache.org



[jira] [Commented] (CB-9490) LG G4 camera application saves photos when using destinationType DATA_URL

2015-09-14 Thread ASF GitHub Bot (JIRA)

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

ASF GitHub Bot commented on CB-9490:


Github user sgrebnov commented on the pull request:


https://github.com/apache/cordova-plugin-camera/pull/115#issuecomment-140016250
  
@cojomojo the fix makes perfect sense, but I see that the code you use is 
very similar to what we have in `checkForDuplicateImage` and looks like that 
function is not required anymore (as I think you cover that case) so I propose 
to rename `checkForDuplicateImage` to `removeTemporaryImages` (or 
`cleanupTempImages`) and move your logic there.


> LG G4 camera application saves photos when using destinationType DATA_URL
> -
>
> Key: CB-9490
> URL: https://issues.apache.org/jira/browse/CB-9490
> Project: Apache Cordova
>  Issue Type: Bug
>  Components: Plugin Camera
> Environment: LG G4, Android 5.1
>Reporter: Cody Balos
>Assignee: Cody Balos
>  Time Spent: 6h
>  Remaining Estimate: 0h
>
> So far this issue only happens on an LG G4 using the stock camera application:
> Using the camera plugin, with destinationType set to DATA_URL,
> the expected functionality is for the base64 string to be returned to the 
> javascript interface, and not saved to the file system without explicitly 
> saving it separately. Using the LG G4 stock camera application, all photos 
> are saved even when using destinationType DATA_URL if the retake option is 
> used. 
> The issue does not occur when using the Google Camera application or Camera 
> 360 (both on the Play Store). 



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

-
To unsubscribe, e-mail: issues-unsubscr...@cordova.apache.org
For additional commands, e-mail: issues-h...@cordova.apache.org



[jira] [Commented] (CB-9490) LG G4 camera application saves photos when using destinationType DATA_URL

2015-09-14 Thread ASF GitHub Bot (JIRA)

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

ASF GitHub Bot commented on CB-9490:


Github user sgrebnov commented on a diff in the pull request:


https://github.com/apache/cordova-plugin-camera/pull/115#discussion_r39375449
  
--- Diff: src/android/CameraLauncher.java ---
@@ -983,12 +983,39 @@ private Cursor queryImgDB(Uri contentStore) {
  * @param newImage
  */
 private void cleanup(int imageType, Uri oldImage, Uri newImage, Bitmap 
bitmap) {
+Uri contentStore = whichContentStore();
+Cursor cursor = queryImgDB(contentStore);
+int currentNumOfImages = cursor.getCount();
+int diff = currentNumOfImages - numPics;
+int id;
+
 if (bitmap != null) {
 bitmap.recycle();
 }
 
-// Clean up initial camera-written image file.
-(new 
File(FileHelper.stripFileProtocol(oldImage.toString(.delete();
+// Check for camera-written image files that are not the chosen 
image
+// Gets rid of inital camera-written image file as well as any 
retakes
+// Addresses issue CD-9490
+if (currentNumOfImages > 0 && diff > 0) {
+cursor.moveToLast();
+id = 
Integer.valueOf(cursor.getString(cursor.getColumnIndex(MediaStore.Images.Media._ID)));
+
+if (imageType == FILE_URI) {
+id--;
+for (int i = diff; i > 0; i--) {
+Uri uri = Uri.parse(contentStore + "/" + id);
+
this.cordova.getActivity().getContentResolver().delete(uri, null, null);
+id--;
+}
+} else {
+for (int i = diff; i > 0; i--) {
--- End diff --

looks like this `for` loop is the same as above; what if we keep only one 
loop, for example

```
if (imageType == FILE_URI) {
id--;
}

for (int i = diff; i > 0; i--) {
Uri uri = Uri.parse(contentStore + "/" + id);
this.cordova.getActivity().getContentResolver().delete(uri, null, null);
id--;
}
```


> LG G4 camera application saves photos when using destinationType DATA_URL
> -
>
> Key: CB-9490
> URL: https://issues.apache.org/jira/browse/CB-9490
> Project: Apache Cordova
>  Issue Type: Bug
>  Components: Plugin Camera
> Environment: LG G4, Android 5.1
>Reporter: Cody Balos
>Assignee: Cody Balos
>  Time Spent: 6h
>  Remaining Estimate: 0h
>
> So far this issue only happens on an LG G4 using the stock camera application:
> Using the camera plugin, with destinationType set to DATA_URL,
> the expected functionality is for the base64 string to be returned to the 
> javascript interface, and not saved to the file system without explicitly 
> saving it separately. Using the LG G4 stock camera application, all photos 
> are saved even when using destinationType DATA_URL if the retake option is 
> used. 
> The issue does not occur when using the Google Camera application or Camera 
> 360 (both on the Play Store). 



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

-
To unsubscribe, e-mail: issues-unsubscr...@cordova.apache.org
For additional commands, e-mail: issues-h...@cordova.apache.org



[jira] [Commented] (CB-9490) LG G4 camera application saves photos when using destinationType DATA_URL

2015-09-10 Thread ASF GitHub Bot (JIRA)

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

ASF GitHub Bot commented on CB-9490:


Github user nikhilkh commented on the pull request:


https://github.com/apache/cordova-plugin-camera/pull/115#issuecomment-139374302
  
@sgrebnov to see if you can help merge this. Do we have the correct test 
coverage for this?


> LG G4 camera application saves photos when using destinationType DATA_URL
> -
>
> Key: CB-9490
> URL: https://issues.apache.org/jira/browse/CB-9490
> Project: Apache Cordova
>  Issue Type: Bug
>  Components: Plugin Camera
> Environment: LG G4, Android 5.1
>Reporter: Cody Balos
>Assignee: Cody Balos
>  Time Spent: 6h
>  Remaining Estimate: 0h
>
> So far this issue only happens on an LG G4 using the stock camera application:
> Using the camera plugin, with destinationType set to DATA_URL,
> the expected functionality is for the base64 string to be returned to the 
> javascript interface, and not saved to the file system without explicitly 
> saving it separately. Using the LG G4 stock camera application, all photos 
> are saved even when using destinationType DATA_URL if the retake option is 
> used. 
> The issue does not occur when using the Google Camera application or Camera 
> 360 (both on the Play Store). 



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

-
To unsubscribe, e-mail: issues-unsubscr...@cordova.apache.org
For additional commands, e-mail: issues-h...@cordova.apache.org



[jira] [Commented] (CB-9490) LG G4 camera application saves photos when using destinationType DATA_URL

2015-09-03 Thread ASF GitHub Bot (JIRA)

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

ASF GitHub Bot commented on CB-9490:


Github user cojomojo commented on the pull request:


https://github.com/apache/cordova-plugin-camera/pull/115#issuecomment-137577342
  
Is this PR still being considered?


> LG G4 camera application saves photos when using destinationType DATA_URL
> -
>
> Key: CB-9490
> URL: https://issues.apache.org/jira/browse/CB-9490
> Project: Apache Cordova
>  Issue Type: Bug
>  Components: Plugin Camera
> Environment: LG G4, Android 5.1
>Reporter: Cody Balos
>Assignee: Cody Balos
>  Time Spent: 6h
>  Remaining Estimate: 0h
>
> So far this issue only happens on an LG G4 using the stock camera application:
> Using the camera plugin, with destinationType set to DATA_URL,
> the expected functionality is for the base64 string to be returned to the 
> javascript interface, and not saved to the file system without explicitly 
> saving it separately. Using the LG G4 stock camera application, all photos 
> are saved even when using destinationType DATA_URL if the retake option is 
> used. 
> The issue does not occur when using the Google Camera application or Camera 
> 360 (both on the Play Store). 



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

-
To unsubscribe, e-mail: issues-unsubscr...@cordova.apache.org
For additional commands, e-mail: issues-h...@cordova.apache.org



[jira] [Commented] (CB-9490) LG G4 camera application saves photos when using destinationType DATA_URL

2015-08-20 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/CB-9490?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=14705933#comment-14705933
 ] 

ASF GitHub Bot commented on CB-9490:


Github user cojomojo commented on the pull request:


https://github.com/apache/cordova-plugin-camera/pull/115#issuecomment-133206691
  
Fixed the PR to only affect the cleanup function. Please re review. 


 LG G4 camera application saves photos when using destinationType DATA_URL
 -

 Key: CB-9490
 URL: https://issues.apache.org/jira/browse/CB-9490
 Project: Apache Cordova
  Issue Type: Bug
  Components: Plugin Camera
 Environment: LG G4, Android 5.1
Reporter: Cody Balos
Assignee: Cody Balos
  Time Spent: 6h
  Remaining Estimate: 0h

 So far this issue only happens on an LG G4 using the stock camera application:
 Using the camera plugin, with destinationType set to DATA_URL,
 the expected functionality is for the base64 string to be returned to the 
 javascript interface, and not saved to the file system without explicitly 
 saving it separately. Using the LG G4 stock camera application, all photos 
 are saved even when using destinationType DATA_URL if the retake option is 
 used. 
 The issue does not occur when using the Google Camera application or Camera 
 360 (both on the Play Store). 



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

-
To unsubscribe, e-mail: issues-unsubscr...@cordova.apache.org
For additional commands, e-mail: issues-h...@cordova.apache.org



[jira] [Commented] (CB-9490) LG G4 camera application saves photos when using destinationType DATA_URL

2015-08-20 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/CB-9490?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=14705800#comment-14705800
 ] 

ASF GitHub Bot commented on CB-9490:


Github user infil00p commented on the pull request:


https://github.com/apache/cordova-plugin-camera/pull/115#issuecomment-133185529
  
You removed part of the cropping functionality, we can't accept this pull 
request as it is.


 LG G4 camera application saves photos when using destinationType DATA_URL
 -

 Key: CB-9490
 URL: https://issues.apache.org/jira/browse/CB-9490
 Project: Apache Cordova
  Issue Type: Bug
  Components: Plugin Camera
 Environment: LG G4, Android 5.1
Reporter: Cody Balos
Assignee: Cody Balos
  Time Spent: 6h
  Remaining Estimate: 0h

 So far this issue only happens on an LG G4 using the stock camera application:
 Using the camera plugin, with destinationType set to DATA_URL,
 the expected functionality is for the base64 string to be returned to the 
 javascript interface, and not saved to the file system without explicitly 
 saving it separately. Using the LG G4 stock camera application, all photos 
 are saved even when using destinationType DATA_URL if the retake option is 
 used. 
 The issue does not occur when using the Google Camera application or Camera 
 360 (both on the Play Store). 



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

-
To unsubscribe, e-mail: issues-unsubscr...@cordova.apache.org
For additional commands, e-mail: issues-h...@cordova.apache.org



[jira] [Commented] (CB-9490) LG G4 camera application saves photos when using destinationType DATA_URL

2015-08-20 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/CB-9490?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=14705908#comment-14705908
 ] 

ASF GitHub Bot commented on CB-9490:


Github user cojomojo commented on the pull request:


https://github.com/apache/cordova-plugin-camera/pull/115#issuecomment-133204027
  
That was not suppose to be removed, must have done that accidentally. Ill 
fix it, and update the PR in a few minutes.


 LG G4 camera application saves photos when using destinationType DATA_URL
 -

 Key: CB-9490
 URL: https://issues.apache.org/jira/browse/CB-9490
 Project: Apache Cordova
  Issue Type: Bug
  Components: Plugin Camera
 Environment: LG G4, Android 5.1
Reporter: Cody Balos
Assignee: Cody Balos
  Time Spent: 6h
  Remaining Estimate: 0h

 So far this issue only happens on an LG G4 using the stock camera application:
 Using the camera plugin, with destinationType set to DATA_URL,
 the expected functionality is for the base64 string to be returned to the 
 javascript interface, and not saved to the file system without explicitly 
 saving it separately. Using the LG G4 stock camera application, all photos 
 are saved even when using destinationType DATA_URL if the retake option is 
 used. 
 The issue does not occur when using the Google Camera application or Camera 
 360 (both on the Play Store). 



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

-
To unsubscribe, e-mail: issues-unsubscr...@cordova.apache.org
For additional commands, e-mail: issues-h...@cordova.apache.org



[jira] [Commented] (CB-9490) LG G4 camera application saves photos when using destinationType DATA_URL

2015-08-18 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/CB-9490?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=14700940#comment-14700940
 ] 

ASF GitHub Bot commented on CB-9490:


GitHub user cojomojo opened a pull request:

https://github.com/apache/cordova-plugin-camera/pull/115

CB-9490 Fixed cleanup function

Modfied cleanup function to deal with camera applications that save photos 
that should have been discarded when the retake option was chosen

You can merge this pull request into a Git repository by running:

$ git pull https://github.com/cojomojo/cordova-plugin-camera CB-9490

Alternatively you can review and apply these changes as the patch at:

https://github.com/apache/cordova-plugin-camera/pull/115.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

This closes #115


commit 5d5ffeacca32ec7676a205353286f7fc649517c5
Author: Cody Balos cjba...@gmail.com
Date:   2015-08-14T21:05:10Z

CB-9490 Fixed cleanup function

Modfied cleanup function to deal with camera applications that save photos 
that should have been discarded when the retake option was chosen




 LG G4 camera application saves photos when using destinationType DATA_URL
 -

 Key: CB-9490
 URL: https://issues.apache.org/jira/browse/CB-9490
 Project: Apache Cordova
  Issue Type: Bug
  Components: Plugin Camera
 Environment: LG G4, Android 5.1
Reporter: Cody Balos
Assignee: Cody Balos
  Time Spent: 6h
  Remaining Estimate: 0h

 So far this issue only happens on an LG G4 using the stock camera application:
 Using the camera plugin, with destinationType set to DATA_URL,
 the expected functionality is for the base64 string to be returned to the 
 javascript interface, and not saved to the file system without explicitly 
 saving it separately. Using the LG G4 stock camera application, all photos 
 are saved even when using destinationType DATA_URL if the retake option is 
 used. 
 The issue does not occur when using the Google Camera application or Camera 
 360 (both on the Play Store). 



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

-
To unsubscribe, e-mail: issues-unsubscr...@cordova.apache.org
For additional commands, e-mail: issues-h...@cordova.apache.org



[jira] [Commented] (CB-9490) LG G4 camera application saves photos when using destinationType DATA_URL

2015-08-18 Thread Cody Balos (JIRA)

[ 
https://issues.apache.org/jira/browse/CB-9490?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=14700938#comment-14700938
 ] 

Cody Balos commented on CB-9490:


Opening a new issue, https://issues.apache.org/jira/browse/CB-9506,  to address 
the above comment, as I believe it is a separate concern and likely won't 
affect the fix for this issue itself. 

 LG G4 camera application saves photos when using destinationType DATA_URL
 -

 Key: CB-9490
 URL: https://issues.apache.org/jira/browse/CB-9490
 Project: Apache Cordova
  Issue Type: Bug
  Components: Plugin Camera
 Environment: LG G4, Android 5.1
Reporter: Cody Balos
Assignee: Cody Balos
  Time Spent: 6h
  Remaining Estimate: 0h

 So far this issue only happens on an LG G4 using the stock camera application:
 Using the camera plugin, with destinationType set to DATA_URL,
 the expected functionality is for the base64 string to be returned to the 
 javascript interface, and not saved to the file system without explicitly 
 saving it separately. Using the LG G4 stock camera application, all photos 
 are saved even when using destinationType DATA_URL if the retake option is 
 used. 
 The issue does not occur when using the Google Camera application or Camera 
 360 (both on the Play Store). 



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

-
To unsubscribe, e-mail: issues-unsubscr...@cordova.apache.org
For additional commands, e-mail: issues-h...@cordova.apache.org



[jira] [Commented] (CB-9490) LG G4 camera application saves photos when using destinationType DATA_URL

2015-08-17 Thread Cody Balos (JIRA)

[ 
https://issues.apache.org/jira/browse/CB-9490?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=14700664#comment-14700664
 ] 

Cody Balos commented on CB-9490:


A decision needs to be made about how this patch is implemented. I have a 
working, and tested fix ready to go, however, it introduces a potential issue 
that is actually kind of in existence already. Currently, the camera plugin 
checks the number of pictures saved to the device before any pictures are 
captured using the camera started via the plugin, and then checks the 
difference between the amount of photos before and after. Relying on this 
method introduces the possibility of deleting photos a user takes outside the 
cordova started camera. For example, consider this scenario: 

A user of a cordova application utilizes a cordova-plugin-camera backed camera 
feature , and while in the camera activity, switches to a different 
application. While in this different application the user takes a photo. Now 
the user returns to the cordova application, and is still in the camera 
activity. They take the photo, and accept it. Now the cleanup process inside 
cordova-plugin-camera begins, but, because of relying on the difference between 
the amount of photos before and after the activity, the photo the user took 
outside of the cordova application is deleted. 

Now the reason, I say this issue is kind of in existence already, is because 
the checkForDuplicateImage function, does have the ill behavior from the above 
example. However, it is limited by its implementation to removing no more than 
2 of the photos taken outside of the cordova application. 

So the question is, does this new issue from the example get ignored because of 
the low probability of it happening in actual use? If, not, what is the best 
way around this?

 LG G4 camera application saves photos when using destinationType DATA_URL
 -

 Key: CB-9490
 URL: https://issues.apache.org/jira/browse/CB-9490
 Project: Apache Cordova
  Issue Type: Bug
  Components: Plugin Camera
 Environment: LG G4, Android 5.1
Reporter: Cody Balos
Assignee: Cody Balos
  Time Spent: 6h
  Remaining Estimate: 0h

 So far this issue only happens on an LG G4 using the stock camera application:
 Using the camera plugin, with destinationType set to DATA_URL,
 the expected functionality is for the base64 string to be returned to the 
 javascript interface, and not saved to the file system without explicitly 
 saving it separately. Using the LG G4 stock camera application, all photos 
 are saved even when using destinationType DATA_URL if the retake option is 
 used. 
 The issue does not occur when using the Google Camera application or Camera 
 360 (both on the Play Store). 



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

-
To unsubscribe, e-mail: issues-unsubscr...@cordova.apache.org
For additional commands, e-mail: issues-h...@cordova.apache.org



[jira] [Commented] (CB-9490) LG G4 camera application saves photos when using destinationType DATA_URL

2015-08-14 Thread Cody Balos (JIRA)

[ 
https://issues.apache.org/jira/browse/CB-9490?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=14697557#comment-14697557
 ] 

Cody Balos commented on CB-9490:


I am implementing a solution and will send a PR. My fix will get rid of using 
the difference of only 1 or 2 for deleting photos. In order to make sure the 
user doesn't lose pictures taken elsewhere (i.e. if they switch to a different 
app and take pictures), I propose a solution implementing the attached 
flowchart.

 LG G4 camera application saves photos when using destinationType DATA_URL
 -

 Key: CB-9490
 URL: https://issues.apache.org/jira/browse/CB-9490
 Project: Apache Cordova
  Issue Type: Bug
  Components: Plugin Camera
 Environment: LG G4, Android 5.1
Reporter: Cody Balos

 So far this issue only happens on an LG G4 using the stock camera application:
 Using the camera plugin, with destinationType set to DATA_URL,
 the expected functionality is for the base64 string to be returned to the 
 javascript interface, and not saved to the file system without explicitly 
 saving it separately. Using the LG G4 stock camera application, all photos 
 are saved even when using destinationType DATA_URL if the retake option is 
 used. 
 The issue does not occur when using the Google Camera application or Camera 
 360 (both on the Play Store). 



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

-
To unsubscribe, e-mail: issues-unsubscr...@cordova.apache.org
For additional commands, e-mail: issues-h...@cordova.apache.org



[jira] [Commented] (CB-9490) LG G4 camera application saves photos when using destinationType DATA_URL

2015-08-14 Thread Cody Balos (JIRA)

[ 
https://issues.apache.org/jira/browse/CB-9490?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=14697431#comment-14697431
 ] 

Cody Balos commented on CB-9490:


Seems that the issue is that most camera applications discard the first photo 
when retake is selected. The LG camera application does not. Thus when 
checkForDuplicateImage runs, the currentNumOfImages is 2 more than numPics, 
rather than 1. Therefore, the images are never deleted. 

I am looking into the best way to fix this. 

 LG G4 camera application saves photos when using destinationType DATA_URL
 -

 Key: CB-9490
 URL: https://issues.apache.org/jira/browse/CB-9490
 Project: Apache Cordova
  Issue Type: Bug
  Components: Plugin Camera
 Environment: LG G4, Android 5.1, Cordova 5.1.1, Cordova Plugin Camera 
 1.2.0. 
Reporter: Cody Balos

 So far this issue only happens on an LG G4 using the stock camera application:
 Using the camera plugin, with destinationType set to DATA_URL,
 the expected functionality is for the base64 string to be returned to the 
 javascript interface, and not saved to the file system without explicitly 
 saving it separately. Using the LG G4 stock camera application, all photos 
 are saved even when using destinationType DATA_URL if the retake option is 
 used. 
 The issue does not occur when using the Google Camera application or Camera 
 360 (both on the Play Store). 



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

-
To unsubscribe, e-mail: issues-unsubscr...@cordova.apache.org
For additional commands, e-mail: issues-h...@cordova.apache.org