Chess icon indicating copy to clipboard operation
Chess copied to clipboard

Capturing a piece tries to use .Send(), which isn't available in WinUI3

Open edgiardina opened this issue 9 months ago • 1 comments

Describe the bug In .NET Maui Windows (Which wraps WinUI 3 basically), the library cannot be consumed because of the .Send in the events.

To Reproduce Create a new .NET MAUI app. Try to capture a piece in the code. See an exception.

System.NotSupportedException: 'The send method is not supported, use Post instead.'
   at Microsoft.UI.Dispatching.DispatcherQueueSynchronizationContext.Send(SendOrPostCallback d, Object state)
   at Chess.ChessBoard.OnCapturedEvent(Piece piece)
   at Chess.ChessBoard.Move(Move move)
   at Chess.MainPage.OnSquareTapped(

Expected behaviour Capturing a piece

Screenshots My repo is public so you can just pull this down: https://github.com/edgiardina/Chess

Additional context Add any other context about the problem here.

edgiardina avatar Mar 26 '25 23:03 edgiardina

Hi!

Hmmm... that's interesting... have you tried some sort of hotfix by changing the Send to Post?

If you did try: did it work?

Thank you for your feedback!

Greetings Sviatoslav

Geras1mleo avatar Mar 27 '25 00:03 Geras1mleo