In my android app, when I use the "swipe back gesture", the app navigates back twice
I debugged it and it turns out, that on Android, when this gesture is used, Avalonia fires two events:
TopLevel.KeyUp (with Key.Escape)
TopLevel.BackRequested
so to fix this, I had to add an OperatingSystem.IsAndroid() check:
In ShellView.cs line 545:
private async void TopLevelOnKeyUp(object? sender, KeyEventArgs e)
{
if (OperatingSystem.IsAndroid())
return;
if (e.Key == Key.Escape)
await Back();
}
Is this a known issue?
Happens with Avalonia 11.3.9