-
Notifications
You must be signed in to change notification settings - Fork 1.4k
Change Log
Arthur edited this page Oct 27, 2018
·
32 revisions
2.8.0
- Fix crash on Android O (thx @juliooa)
- Update to support library to AndroidX (thx @mradzinski)
- Handle failure when selecting non image file (thx @uncledoc)
- More translations (thx @jkwiecien, @david-serrano)
2.7.0
- Update gradle wrapper to 4.4
- Update support library to 27.1.1 and set is statically! (thx @androideveloper)
- Fix NPE in activity creation by tools (thx @unverbraucht)
- More translations (thx @gwharvey, @dlackty, @JairoGeek, @shaymargolis)
2.6.0
- Update to sdk v27
- Update to gradle v3
2.5.1
- Try solve manifest merger issue by adding
transitive
flag #405 (thx @j-garin) - Use thread pool executors for async image loading and cropping operations to prevent app hang if default executor is busy (thx @ruifcardoso)
- Fix image rotation breaking min/max crop result restrictions #401
- Propagate all extra data set on start crop activity intent back in crop result intent #352
2.5.0
- Update to sdk v26
- Update gradle plugin to 2.0
- Update min sdk version to 14
- Fix NPE in
getWholeImageRect
- Remove
crop_image_menu_crop
drawable support, replace withsetCropMenuCropButtonIcon
builder api. - Support setting crop button title via builder api.
- Add string resource for "no permissions" toast.
2.4.7
- Fix toolbar menu crop icon sometimes appears with random icon (#305)
- Use CharSequence instead of string for activity title (thx @KentHawkings) (#297)
- Fix class not found exception on some Samsung devices (Huge thanks to @Vantablack) (#332)
- Add original image dimensions to CropResult (Thanks @gazialankus) (#327)
- Making the library JitPack-friendly (Thanks @gazialankus) (#325)
- Allow a Fragment to call the startPickImageActivity help method in CropImage (Thanks @cdavietei) (#315)
2.4.5
- Fix undefined drawable in Android Studio 3.0 (thx @adrien-aubel)
2.4.4
- Fix image exif (rotation) data not always extracted during image loading (thx @danikula).
2.4.3
- Adding option to omit camera intents on getPickImageChooserIntent (thx Hugo Rossi)
- Portuguese Language localization (thx Hugo Rossi)
- Removed saving bitmap into parcel in
onSaveInstanceState
to preventTransactionTooLargeException
- By default nothing will happen and the view will be restored empty (if cropping image loaded using bitmap).
- Added config
SaveBitmapToInstanceState
to enable saving bitmap to temp file so it can be restored (default is false because of possible performance implications). - Always prefer using URI to load image from cropping!
- Fix restore state not restoring rotation.
- Fix initial crop window may be in invalid position because reading previous image instance state.
2.4.2
- Fix instance state saved before any image loaded resulted in corrupted initial crop rectangle.
- Fix corners of crop overlay offset for oval shape resulting in confusing UI (#256).
- Fix support for negative rotation values for CropImageActivity.
- Add
start
method that acceptsandroid.app.Fragment
, annotated with@RequiresApi
11
2.4.0
- Super simple crop activity quick start flow that handles URI and permissions (huge thanks to @adwiv)
- Add image horizontal/vertical flipping during cropping (huge thanks to @tibbi).
- Handle OOM error for cropping set bitmap object, previously only image set by URI handled OOM.
- Allows for rotation degrees to be negative, fixes operator-precedence-related bug in flipAxes computation (thx Tim Cooke)
- Added crop overlay released listener (thx Richard Yee)
- Added originalUri and originalBitmap to CropResult object.
- Fix
resetCropRect()
resetting image rotation to 0 instead of the original exif data. - Fix ignoring image rotation data in
setImageBitmap(Bitmap, ExifInterface )
method. - Removed deprecated listeners.
2.3.1
- Fix image picker for xiaomi and huawei phones (thx @nicolabeghin)
- Fix crop window get corrupted on
CropImageView
resize.
2.3.0
- Change required width/height behavior to support resizing (inside/fit/exact) see wiki for details.
- Add sampling fallback to lower cropped image resolution on OOM error (if image loaded from URI).
- Setting aspect ratio will also set it to fixed, to help with confusion, add clear aspect ratio method.
- Add support for setting min/max crop result size in code on CropImageView.
- Fix cropping failing bug when skia fails region cropping.
- Add Fallback to Intent.ACTION_PICK if no intent found for Intent.ACTION_GET_CONTENT (thx geolyth)
- Multi touch support for cropping window (experimental, thx bbwharris)
- BREAKING CHANGES:
- If you previously used requested width/height the default behavior now is to resize inside the cropped image, to preserve the previous behavior you need to pass the SAMPLING option.
-
OnGetCroppedImageCompleteListener
andOnSaveCroppedImageCompleteListener
is deprecated, useOnCropImageCompleteListener
that combines the two and provides the result object as crop activity. - Set aspect ratio also sets fixed aspect ratio to true, if this is not the desired behavior set the fix aspect ratio flag manually or call the method after calling set aspect ratio.
2.2.5
- Fix to webp file extension (thx Nathan)
- Fix wrong initial crop window when image contains exif data.
- Added corners to circular crop window, can be removed by setting
BorderCornerThickness
to 0.
2.2.3
- Fix Android state restore overrides state set by client.
2.2.2
- Fix rotation zooms and changes aspect ratio when fixed aspect ratio is used.
2.2.1
- Fix listeners getting garbage collected bug (thx @TheFinestArtist)
2.2.0
- Fix non-straight angle rotation handling.
- Add activity counter-clockwise rotation button (configurable, hidden by default).
- Add activity rotation degrees configuration (default 90)
2.1.4
- Support for requesting CAMERA permission for android M when CAMERA is requested in the manifest.
- Add
pick_image_intent_chooser_title
for changing and localizing pick image chooser title (thx maksymkhar). - NPE when clicking crop twice fast (thx Jesse).
2.1.3
- add
noOutputImage
option for crop image activity. - add more customization to crop image activity.
2.1.2
- Minor fixes.
2.1.1
- Built-in
CropImageActivity
for quick start and common scenarios. - Save cropped image to Uri API
saveCroppedImageAsync(Uri)
. - Handle possible out-of-memory in image load by down-sampling until succeed.
- Minor fixes.
2.0.1 (Beta)
- Fix counter clockwise rotation resulting in negative degrees (#54).
2.0.0 (Beta)
- Auto-zoom: zoom-in when crop window takes less than 50% of the image, zoom-out when more than 65%.
- Handle cropping of non-straight angles rotations for URI loaded images.
- Improve performance for image rotation.
- Improve performance for rotation due to exif orientation data.
- Improve performance for orientation change.
- Preserve crop window on rotations for straight angles - 90/180/270.
- Preserve crop window on orientation change.
- Handle max allowed texture size on device by down-sampling to be within the limit.
- API breaking changes:
- Renamed
CropImageHelper
toCropImage
- Removed
getActualCropRect()
andgetActualCropRectNoRotation()
, replaced by 'getCropPoints()' and 'getCropRect()'. - Moved to custom
CropImageView.ScaleType
for 'setScaleType()' - Removed
CropShape
fromgetCroppedImage
API, addedCropImage.toOvalBitmap
. - Known issues:
- Boundaries and orientation change for non-straight angle rotation of images.
1.2.5
- Fix off-by-1 error in cropping rectangle, double verify width == height for 1:1 fixed aspect ratio.
1.2.4
- add fallback in crop to use
BitmapFactory
whenBitmapRegionDecoder
fails
1.2.3
- Fix
getActualCropRect
to adjust by sampling size for images loaded from URI. - Fix crop window size bounded with fixed aspect ratio and move of a single edge.
- Added
CropImageHelper
class to simplify cropping image work.
1.2.2 (beta)
- Fix
setShowCropOverlay(boolean)
not working properly. - Fix crop window bounds issue when cropping image is too small relative to min/max bounds with fixed aspect ratio.
- Fix crop window reset on on-screen keyboard show/hide.
1.2.1 (beta)
- Fix crop window resize bug with fixed aspect ratio
- Add
getRotatedDegrees()
to get how much the image was rotated during cropping - Add
setCropRect(Rect)
to set initial cropping window location and size to specific window on the image.
1.2.0 (beta)
Due too large changes in the internals please consider this a beta release, if you use it be sure to test is thoroughly and report any bugs you find (report no bugs will also be awesome) or use 1.1.0 until I feel 1.2.* is stable enough.
- Rewrite internal crop window handling.
- Add
crop
prefix to all customization resources to prevent naming collision (breaking change). - Add
CropImageView.Guidelines
enum of guidelines config instead of integer (breaking change). - Change custom attributes types to
dimension
where appropriate (breaking change). - Add
showCropOverlay
attribute andsetShowCropOverlay(boolean)
method allowing to hide/show crop overlay UI for animation or element transition. - Add
cropInitialCropWindowPaddingRatio
customization [0 - 0.5) to control initial crop window padding from image borders relative to image size. - Add min limit config on cropping window width/height in the UI (
cropMinCropWindowWidth
,cropMinCropWindowHeight
) - Add min/max config on cropping image result width/height (
cropMinCropResultWidthPX
,cropMinCropResultHeightPX
,cropMaxCropResultWidthPX
,cropMaxCropResultHeightPX
)
1.1.1
- Add customization support for border line, border corner, guidelines and background.
- Fix progress bar not showing on loading if previously bitmap was directly set.
1.1.0
- Deprecated
setImageUri(Uri)
. - Added
setImageUriAsync(Uri)
andgetCroppedImageAsync()
for better handling of slow image loading/decode/cropping. - Fixed Save/Restore state handling, proper orientation change expirience.
- Bug fixes on rotation and bitmap recycled error.
1.0.7
- Added
setSnapRadius(float)
allowing to disable snap by setting 0. - Nicer rectengular crop border.
- Fix oval shape rendering on old devices by disabling hardware rendering when required.