hansemannn / titanium-image-crop

An easy to use iOS image cropping tool based on TOCropViewController.
MIT License
40 stars 5 forks source link

ImageCrop dialog opens only once #2

Closed designbymind closed 3 years ago

designbymind commented 3 years ago

First off, this is an awesome module, Thank You for open sourcing =]

After successfully showing the ImageCrop dialog, then clicking the "Cancel" button, then attempting to show the ImageCrop dialog again, nothing happens (no dialog shows, no error thrown).

Any idea why the above is happening? — Possibly something to do with the ImageCrop not being able to take the position as topPresentedController?

Side Note: when attempting to open ImageCrop directly after selecting an image from Photo Gallery (in the success callback of Ti.Media.openPhotoGallery), ImageCrop will not display without a setTimeout. — Possibly a race condition for the topPresentedController?

TiSDK: 10.1.0.v20210806050748 iOS: 14.5

hansemannn commented 3 years ago

Thanks! Fixed in https://github.com/hansemannn/titanium-image-crop/commit/6f2fe4e68b5666e74b213284e1929698c6265068