TappedRoutedEventArgs.GetPosition throws a 'Specified method is not supported' exception when a 'relativeTo' parameter is specified.
The correct position is returned with no exception thrown.
c#
private void TappedEventHandler(object sender, TappedRoutedEventArgs args)
{
try
{
var position = args.GetPosition(args.OriginalSource as UIElement);
coordinates.Text = $"Clicked: {position.X}, {position.Y}";
}
catch (Exception e)
{
coordinates.Text = $"Exception while calling TappedRoutedEventArgs: {e.Message}";
}
}
Package Version(s):
Uno.UI v 1.45.0
Uno.Wasm.Bootstrap v1.0.0
Affected platform(s):
Visual Studio:
Relevant plugins:
A full working reproduction can be found in this repository: https://github.com/ibebbs/UnoIssues
Resolved by Uno.UI v2.0.512-dev.3670
Most helpful comment
Resolved by Uno.UI v2.0.512-dev.3670