Closed AlanFloyd closed 2 years ago
Could you provide test project which reproduces this issue
This is the code I am using:
void crop_image(String PhotoPath)
{
_ = ImageCropper.Current.Crop(new CropSettings()
{
AspectRatioX = 1,
AspectRatioY = 1,
CropShape = CropSettings.CropShapeType.Rectangle
}, PhotoPath).ContinueWith(t =>
{
if (t.IsFaulted)
{
var ex = t.Exception;
//alert user
}
else if (t.IsCanceled)
{
var ex = t.Exception;
//do nothing
}
else if (t.IsCompleted)
{
var result = t.Result;
image.Source = result;
is_saved = false;
}
});
}
PhotoPath has a valid path. Also the bool is_saved is not updated, this happens only on iOS. On Android it works fine. I am using Visual Studio for Mac 8.9.10 (build 4)
Hi Alex,
i found it:
Device.BeginInvokeOnMainThread(() =>
{
image.Source = result;
is_saved = false;
});
Hello,
trying to use the control. As Android is working fine, opens the image, can crop it and it is showing up in the activity. But on iOS it is not working in the same way, the image is opened, it can be cropped, but it is not showing in the activity. In debugger i can see: 1. return isCompleted = true, t.result shows the path to the Document directory and the corresponding cropped jpg, i assign image.Source = result, but the image is not shown on screen
Thanks for help Dietmar