SkiaSharp is a cross-platform 2D graphics API for .NET platforms based on Google's Skia Graphics Library. It provides a comprehensive 2D API that can be used across mobile, server and desktop models to render images.
When having a SKCanvasView in front of a button the touch events don't reach the button on iOS even if EnableTouchEvents is set to false. Same when setting EnableTouchEvents to true and setting Handeled property of TouchEventArgs to false.
On Andorid everything works as expected.
Code
Case 0:
<forms:SKCanvasView EnableTouchEvents="false" HorizontalOptions="FillAndExpand" VerticalOptions="FillAndExpand" PaintSurface="Handle_PaintSurface" />
When setting EnableTouchEvents to false touch gets passed through to underlying elements. Same when handling touch events and setting handled to false for TouchEventArgs. Just like it works on Android.
Description
When having a SKCanvasView in front of a button the touch events don't reach the button on iOS even if EnableTouchEvents is set to false. Same when setting EnableTouchEvents to true and setting Handeled property of TouchEventArgs to false.
On Andorid everything works as expected.
Code
Case 0:
<forms:SKCanvasView EnableTouchEvents="false" HorizontalOptions="FillAndExpand" VerticalOptions="FillAndExpand" PaintSurface="Handle_PaintSurface" />
Case 1:
<forms:SKCanvasView EnableTouchEvents="true" HorizontalOptions="FillAndExpand" VerticalOptions="FillAndExpand" Touch="SKCanvasView_OnTouch" PaintSurface="Handle_PaintSurface" />
private async void SKCanvasView_OnTouch(object sender, SKTouchEventArgs e) { e.Handled = false; }
Expected Behavior
When setting EnableTouchEvents to false touch gets passed through to underlying elements. Same when handling touch events and setting handled to false for TouchEventArgs. Just like it works on Android.
Actual Behavior
See description.
Basic Information
Reproduction Link
See for demo application: https://github.com/Alex-Witkowski/SkiaSharpTouchTest