You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cordova.apache.org by sh...@apache.org on 2012/04/13 01:18:51 UTC

git commit: Revert "add cropToSize param to camera.getPicture"

Updated Branches:
  refs/heads/master 97775936f -> 7e1461bcd


Revert "add cropToSize param to camera.getPicture"

This reverts commit 4c1f4dc98859eabf86bb510c73dbc1b9eae356e2.


Project: http://git-wip-us.apache.org/repos/asf/incubator-cordova-js/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-cordova-js/commit/7e1461bc
Tree: http://git-wip-us.apache.org/repos/asf/incubator-cordova-js/tree/7e1461bc
Diff: http://git-wip-us.apache.org/repos/asf/incubator-cordova-js/diff/7e1461bc

Branch: refs/heads/master
Commit: 7e1461bcdd4e67c43464a515a22a8b65f3146878
Parents: 9777593
Author: shazron <sh...@gmail.com>
Authored: Thu Apr 12 16:16:41 2012 -0700
Committer: shazron <sh...@gmail.com>
Committed: Thu Apr 12 16:16:41 2012 -0700

----------------------------------------------------------------------
 lib/common/plugin/Camera.js |   10 ++--------
 1 files changed, 2 insertions(+), 8 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-cordova-js/blob/7e1461bc/lib/common/plugin/Camera.js
----------------------------------------------------------------------
diff --git a/lib/common/plugin/Camera.js b/lib/common/plugin/Camera.js
index f72d6ea..d104707 100644
--- a/lib/common/plugin/Camera.js
+++ b/lib/common/plugin/Camera.js
@@ -93,19 +93,13 @@ cameraExport.getPicture = function(successCallback, errorCallback, options) {
     	correctOrientation = options.correctOrientation <=0 ? false : true;
     }
     var saveToPhotoAlbum = false;
-    if (typeof options.saveToPhotoAlbum == "boolean") {
+	if (typeof options.saveToPhotoAlbum == "boolean") {
     	saveToPhotoAlbum = options.saveToPhotoAlbum;
     } else if (typeof options.saveToPhotoAlbum == "number") {
     	saveToPhotoAlbum = options.saveToPhotoAlbum <=0 ? false : true;
     }
-    var cropToTargetSize = false;
-    if (typeof options.cropToTargetSize == "boolean") {
-        cropToTargetSize = options.cropToTargetSize;
-    } else if (typeof options.cropToTargetSize == "number") {
-        cropToTargetSize = options.cropToTargetSize <= 0 ? false : true;
-    }
 
-    exec(successCallback, errorCallback, "Camera", "takePicture", [quality, destinationType, sourceType, targetWidth, targetHeight, encodingType, mediaType, allowEdit, correctOrientation, saveToPhotoAlbum, cropToTargetSize]);
+    exec(successCallback, errorCallback, "Camera", "takePicture", [quality, destinationType, sourceType, targetWidth, targetHeight, encodingType, mediaType, allowEdit, correctOrientation, saveToPhotoAlbum]);
 }
 
 module.exports = cameraExport;