From fb19294fcca95fe355f335c58fa379ebb0cc0410 Mon Sep 17 00:00:00 2001 From: Osei Fortune Date: Mon, 9 May 2016 12:15:31 -0400 Subject: [PATCH] Update camera.android.ts --- camera/camera.android.ts | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/camera/camera.android.ts b/camera/camera.android.ts index f1fa8e8dd..82a7485bf 100644 --- a/camera/camera.android.ts +++ b/camera/camera.android.ts @@ -44,9 +44,9 @@ export var takePicture = function (options?): Promise { appModule.android.onActivityResult = previousResult; if (requestCode === REQUEST_IMAGE_CAPTURE && resultCode === android.app.Activity.RESULT_OK) { - + var imageSource: typeof imageSourceModule = require("image-source"); if (saveToGallery) { - resolve(picturePath); + resolve({image:imageSource.fromFile(picturePath) ,path:picturePath}); } else { var options = new android.graphics.BitmapFactory.Options(); options.inJustDecodeBounds = true; @@ -89,8 +89,7 @@ export var takePicture = function (options?): Promise { break; } - var imageSource: typeof imageSourceModule = require("image-source"); - resolve(imageSource.fromNativeSource(scaledSizeImage), picturePath); + resolve({image:imageSource.fromNativeSource(scaledSizeImage), path:picturePath}); } }