Skip to content

Commit

Permalink
Release 2.3.17
Browse files Browse the repository at this point in the history
  • Loading branch information
Drjacky committed Aug 23, 2022
1 parent 7594348 commit de77530
Show file tree
Hide file tree
Showing 3 changed files with 30 additions and 26 deletions.
6 changes: 5 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,12 @@ adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).

## [Unreleased]

* Migrate to Kotlin 1.7.0
## [2.3.17] - 2022-08-23

* Migrate to Kotlin 1.7.10
* Update internal dependencies
* Let user pick multiple files in the gallery mode
* Let user define the output format

## [2.1.16] - 2022-06-22

Expand Down
46 changes: 23 additions & 23 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -63,15 +63,15 @@ Where `$libVersion` = [![libVersion](https://img.shields.io/github/release/drjac
**Java**

```java
ActivityResultLauncher<Intent> launcher =
registerForActivityResult(new ActivityResultContracts.StartActivityForResult(), (ActivityResult result) -> {
if (result.getResultCode() == RESULT_OK) {
Uri uri = result.getData().getData();
// Use the uri to load the image
} else if (result.getResultCode() == ImagePicker.RESULT_ERROR) {
// Use ImagePicker.Companion.getError(result.getData()) to show an error
}
});
ActivityResultLauncher<Intent> launcher=
registerForActivityResult(new ActivityResultContracts.StartActivityForResult(),(ActivityResult result)->{
if(result.getResultCode()==RESULT_OK){
Uri uri=result.getData().getData();
// Use the uri to load the image
}else if(result.getResultCode()==ImagePicker.RESULT_ERROR){
// Use ImagePicker.Companion.getError(result.getData()) to show an error
}
});
```

**If you want both Camera and Gallery:**
Expand All @@ -88,22 +88,22 @@ Where `$libVersion` = [![libVersion](https://img.shields.io/github/release/drjac
**Java**

```java
ImagePicker.Companion.with(this)
.crop()
.cropOval()
ImagePicker.Companion.with(this)
.crop()
.cropOval()
.maxResultSize(512,512,true)
.provider(ImageProvider.BOTH) //Or bothCameraGallery()
.createIntentFromDialog((Function1)(new Function1(){
public Object invoke(Object var1) {
this.invoke((Intent) var1);
return Unit.INSTANCE;
}

public final void invoke(@NotNull Intent it) {
Intrinsics.checkNotNullParameter(it, "it");
launcher.launch(it);
}
}));
public Object invoke(Object var1){
this.invoke((Intent)var1);
return Unit.INSTANCE;
}

public final void invoke(@NotNull Intent it){
Intrinsics.checkNotNullParameter(it,"it");
launcher.launch(it);
}
}));
```

**If you want just one option:**
Expand All @@ -122,7 +122,7 @@ Where `$libVersion` = [![libVersion](https://img.shields.io/github/release/drjac
**Java**

```java
ImagePicker.Companion.with(this)
ImagePicker.Companion.with(this)
.crop() //Crop image(Optional), Check Customization for more option
.cropOval() //Allow dimmed layer to have a circle inside
.cropFreeStyle() //Let the user to resize crop bounds
Expand Down
4 changes: 2 additions & 2 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@
buildscript {
ext {
kotlin_version = '1.7.10'
versionCode = 36
versionName = '2.1.16'
versionCode = 37
versionName = '2.3.17'
}

repositories {
Expand Down

0 comments on commit de77530

Please sign in to comment.