Return-Path: X-Original-To: apmail-cordova-dev-archive@www.apache.org Delivered-To: apmail-cordova-dev-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 1850DE9A4 for ; Wed, 16 Jan 2013 22:00:16 +0000 (UTC) Received: (qmail 21711 invoked by uid 500); 16 Jan 2013 22:00:15 -0000 Delivered-To: apmail-cordova-dev-archive@cordova.apache.org Received: (qmail 21690 invoked by uid 500); 16 Jan 2013 22:00:15 -0000 Mailing-List: contact dev-help@cordova.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@cordova.apache.org Delivered-To: mailing list dev@cordova.apache.org Received: (qmail 21680 invoked by uid 500); 16 Jan 2013 22:00:15 -0000 Delivered-To: apmail-incubator-callback-dev@incubator.apache.org Received: (qmail 21676 invoked by uid 99); 16 Jan 2013 22:00:15 -0000 Received: from arcas.apache.org (HELO arcas.apache.org) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 16 Jan 2013 22:00:15 +0000 Date: Wed, 16 Jan 2013 22:00:15 +0000 (UTC) From: "Thomas Dinger (JIRA)" To: callback-dev@incubator.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Commented] (CB-2165) The "saveToPhotoAlbum" option for Camera.getPicture does not work with Cordova 2.2/Android MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 [ https://issues.apache.org/jira/browse/CB-2165?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13555505#comment-13555505 ] Thomas Dinger commented on CB-2165: ----------------------------------- Thanks Simon. I was able to add some JS code to convert "true" to true. The reason it was "true" to begin with is because the camera options JSON is created using an XML-to-JSON conversion, and apparently that logic defaults to specifying all of the JSON values as strings. It is worth noting that the values for quality, targetWidth, and targetHeight are also strings, not numbers. But they work as expected because of the type conversion logic in Cordova's getPicture() function. Would it be possible to add similar type conversion logic in getPicture(), to handle values that are expected to be boolean, but are passed in as stings? > The "saveToPhotoAlbum" option for Camera.getPicture does not work with Cordova 2.2/Android > ------------------------------------------------------------------------------------------ > > Key: CB-2165 > URL: https://issues.apache.org/jira/browse/CB-2165 > Project: Apache Cordova > Issue Type: Bug > Components: CordovaJS > Affects Versions: 2.2.0 > Environment: Cordova 2.2, Android 2.3.4 > Reporter: Thomas Dinger > Assignee: Simon MacDonald > Priority: Minor > > The following JS call results in a call to the success function when the picture is taken, but the picture is not added to the photo library. > 01-08 09:27:53.470: D/CordovaLog(4089): getPicture() { > 01-08 09:27:53.470: D/CordovaLog(4089): "targetHeight": "600", > 01-08 09:27:53.470: D/CordovaLog(4089): "targetWidth": "600", > 01-08 09:27:53.470: D/CordovaLog(4089): "saveToPhotoAlbum": "true", > 01-08 09:27:53.470: D/CordovaLog(4089): "quality": "50", > 01-08 09:27:53.470: D/CordovaLog(4089): "destinationType": 1, > 01-08 09:27:53.470: D/CordovaLog(4089): "mediaType": 0, > 01-08 09:27:53.470: D/CordovaLog(4089): "encodingType": 0, > 01-08 09:27:53.470: D/CordovaLog(4089): "allowEdit": "false", > 01-08 09:27:53.470: D/CordovaLog(4089): "sourceType": 1 > 01-08 09:27:53.470: D/CordovaLog(4089): } -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators For more information on JIRA, see: http://www.atlassian.com/software/jira