Skip to content

[BUG] MediaSource not Disposed on Exit #2264

@ne0rrmatrix

Description

@ne0rrmatrix

Is there an existing issue for this?

  • I have searched the existing issues

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

Current Behavior

When exiting page with media element and then opening page again it can fail to load a URL when setting source. This occurs on the third try. I also noticed when leaving page and trying to enter page you need to first need to load a different page then back to media element. This only happens in Windows. The controls also do not work as expected and are missing icons.

Expected Behavior

When you exit a page you should be able to enter the page again. If you load a page with a media element it should load the URL set as source.

Steps To Reproduce

  1. Open sample app

  2. Navigate to media element page

  3. exit page

  4. enter page

  5. it fails to enter page

  6. Open sample app

  7. Navigate to media element page

  8. exit page

  9. enter another page

  10. exit that page

  11. enter media element

  12. Repeat step 3 to 6 another 2 times

  13. On second repeat of steps 3 to 6 if will fail to load URL.

Link to public reproduction project repository

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

Environment

- .NET MAUI CommunityToolkit: 9.x
- OS:Windows 10 Build 10.0.19041.0
- .NET MAUI:8.x

Anything else?

This is an issue that has existed for multiple major version of Media Element. From what I can test it affects nearly all versions.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working📽️ MediaElementIssue/PR that has to do with MediaElement

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions