I did a bit of digging and found that PanGestureRecognizer isn't currently raising its PanUpdatedEvent event with the Completed status. Comparing the logic in the current ScrollGestureRecognizer, the most significant difference I can see is that the PanGestureRecognizer isn't keeping track of which pointer is responsible for the gesture, and it's capturing the pointer both with e.Pointer.Capture(_inputElement); and `Capture(e.Pointer).
Updating the recognizer to track the pointer, and only Capture(e.Pointer) means the Swipe control starts behaving itself:
I noticed that the Swipe control isn't working at the moment:
https://github.com/AvaloniaUI/Avalonia.Labs/assets/4577868/a128bbf0-a688-448c-bebb-391877fdbe64
I did a bit of digging and found that
PanGestureRecognizer
isn't currently raising itsPanUpdatedEvent
event with theCompleted
status. Comparing the logic in the currentScrollGestureRecognizer
, the most significant difference I can see is that thePanGestureRecognizer
isn't keeping track of which pointer is responsible for the gesture, and it's capturing the pointer both withe.Pointer.Capture(_inputElement);
and `Capture(e.Pointer).Updating the recognizer to track the pointer, and only
Capture(e.Pointer)
means theSwipe
control starts behaving itself:https://github.com/AvaloniaUI/Avalonia.Labs/assets/4577868/26feff2c-334a-4cfe-98f4-19ead7b80d0b
I've a PR incoming with the changes I've made for review.