CommunityToolkit / Maui

The .NET MAUI Community Toolkit is a community-created library that contains .NET MAUI Extensions, Advanced UI/UX Controls, and Behaviors to help make your life as a .NET MAUI developer easier
https://learn.microsoft.com/dotnet/communitytoolkit/maui
MIT License
2.1k stars 340 forks source link

[BUG] Clicking on full screen button while popup is open in Windows crashes the Sample application. #1869

Open ne0rrmatrix opened 1 month ago

ne0rrmatrix commented 1 month ago

Is there an existing issue for this?

Did you read the "Reporting a bug" section on Contributing file?

Current Behavior

Application crashes when clicking on full screen button while a popup of media element is visible.

Expected Behavior

Not sure. What do we want to do when we have created a popup with mediaElement when it is also in the background behind it? Do we want to remove the full screen button so it is not clickable when a popup is present? Not sure how we would do that off the top of my head. We would have to detect a popup becoming active and then hiding the full screen button? Maybe a solution?

Steps To Reproduce

  1. Build and run the sample app.
  2. Navigate to Media Element Page.
  3. Click on popup.
  4. Click on full screen button.

Link to public reproduction project repository

https://github.com/CommunityToolkit/Maui/tree/main/samples

Environment

- .NET MAUI CommunityToolkit:9.0.0
- OS: Windows 10 Build 10.0.19041.0
- .NET MAUI: 8.0.14
- .NET Maui CommunityToolkit MediaElement: 3.1.1

Sample

https://github.com/CommunityToolkit/Maui/assets/4167863/28571d9b-4823-4dd9-b6f5-68081d6f7b63

It looks like this is a weird edge case where it is possible to crash the app by clicking on a button. Full screen button should not be visible and also disabled while a popup is present. Or rewritten to handle full screen switch if popup is present.

bricefriha commented 3 weeks ago

I might have an idea of how to fix that. Would you mind if I take a look at it? 🙂