Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

API: Deprecate CropImageContract. #637

Merged
merged 1 commit into from
Aug 5, 2024
Merged

Conversation

vanniktech
Copy link
Contributor

No description provided.

@vanniktech vanniktech merged commit 7eb3191 into main Aug 5, 2024
2 checks passed
@vanniktech vanniktech deleted the deprecate-CropImageContract branch August 5, 2024 10:00
@david-allison
Copy link

@vanniktech Is there a brief rationale/documentation on the reasons for this deprecation?

PS: Thank you for the library!

@vanniktech
Copy link
Contributor Author

These contracts cause a lot of problems because people want to customize it, they expect different functionality, then in addition they want the Activity to be different with different feature sets, etc. Maintaining all of this becomes a mess, additionally there was the migration from the previous OnActivityResult mechanism to the new Contract API.

I want this library to evolve and support more things. The focus should be on the Image Cropping, not things that are around like the Activity & mechanism how images are loaded (Gallery/Camera/etc). Therefore I've decided to deprecate the provided Activity & the Contracts. I will keep them around and remove them with a 5.x version. The code works, so if you want to get rid of the deprecation, just copy paste the code into your application and you're done.

CropImageView is the way forward. Then everyone can decide how it should be displayed (Activity/Fragment/Compose) and what it should display (Image via Camera/Gallery/etc) and also when.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants