mirror of
https://github.com/status-im/react-native-image-resizer.git
synced 2025-01-14 16:55:59 +00:00
change build.gradle, make it easey to run
This commit is contained in:
parent
452f4fafdc
commit
99563c8b32
@ -2,7 +2,7 @@ apply plugin: 'com.android.library'
|
|||||||
|
|
||||||
android {
|
android {
|
||||||
compileSdkVersion 23
|
compileSdkVersion 23
|
||||||
buildToolsVersion "23.0.2"
|
buildToolsVersion "23.0.1"
|
||||||
|
|
||||||
defaultConfig {
|
defaultConfig {
|
||||||
minSdkVersion 16
|
minSdkVersion 16
|
||||||
@ -19,5 +19,5 @@ android {
|
|||||||
|
|
||||||
dependencies {
|
dependencies {
|
||||||
compile 'com.android.support:appcompat-v7:23.1.0'
|
compile 'com.android.support:appcompat-v7:23.1.0'
|
||||||
compile 'com.facebook.react:react-native:0.14.+'
|
compile 'com.facebook.react:react-native:+'
|
||||||
}
|
}
|
||||||
|
@ -112,7 +112,7 @@ class ImageResizer {
|
|||||||
|
|
||||||
public static String createResizedImage(Context context, String imagePath, int newWidth,
|
public static String createResizedImage(Context context, String imagePath, int newWidth,
|
||||||
int newHeight, Bitmap.CompressFormat compressFormat,
|
int newHeight, Bitmap.CompressFormat compressFormat,
|
||||||
int quality, int rotation) {
|
int quality, int rotation) throws IOException{
|
||||||
|
|
||||||
Bitmap resizedImage = ImageResizer.rotateImage(ImageResizer.resizeImage(imagePath, newWidth, newHeight,context), rotation);
|
Bitmap resizedImage = ImageResizer.rotateImage(ImageResizer.resizeImage(imagePath, newWidth, newHeight,context), rotation);
|
||||||
return ImageResizer.saveImage(resizedImage, context.getCacheDir(),
|
return ImageResizer.saveImage(resizedImage, context.getCacheDir(),
|
||||||
|
Loading…
x
Reference in New Issue
Block a user