From b428841931c74be027ceee8c491506339f03c4ef Mon Sep 17 00:00:00 2001 From: parveshneedhoo Date: Tue, 24 Oct 2023 15:19:07 +0400 Subject: [PATCH] save image width and height for android --- src/android/ImagePicker.java | 14 +++++++++++++- 1 file changed, 13 insertions(+), 1 deletion(-) diff --git a/src/android/ImagePicker.java b/src/android/ImagePicker.java index 3149e678..22091d43 100644 --- a/src/android/ImagePicker.java +++ b/src/android/ImagePicker.java @@ -8,6 +8,7 @@ import android.content.Intent; import android.content.pm.PackageManager; import android.database.Cursor; +import android.graphics.BitmapFactory; import android.graphics.Color; import android.net.Uri; import android.os.Build; @@ -76,6 +77,7 @@ public boolean execute(String action, final JSONArray args, final CallbackContex public void onActivityResult(int requestCode, int resultCode, Intent data) { ExecutorService executor = Executors.newSingleThreadExecutor(); + ArrayList imageInfos = new ArrayList<>(); executor.execute(() -> { try { cordova.getActivity().runOnUiThread(() -> { @@ -111,7 +113,17 @@ public void onActivityResult(int requestCode, int resultCode, Intent data) { } } } - JSONArray res = new JSONArray(fileURIs); + for (int i=0; i