Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[BUG] Back Button not working in Fullscreen mode #1753

Closed
2 tasks done
South2AK opened this issue Mar 14, 2024 · 4 comments · Fixed by #1761
Closed
2 tasks done

[BUG] Back Button not working in Fullscreen mode #1753

South2AK opened this issue Mar 14, 2024 · 4 comments · Fixed by #1761
Labels
bug Something isn't working 📽️ MediaElement Issue/PR that has to do with MediaElement unverified

Comments

@South2AK
Copy link

South2AK commented Mar 14, 2024

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 using a back button (tested on two android devices) and having FullScreen toggled via the newly added fullscreen button the page simply goes back when using the back button while the mediaElement is still in fullscreen mode and running.

Expected Behavior

Back button should simply stop the full screen mode and go back to the page the media element is on. When using the back button then, it should go back a page.

Steps To Reproduce

  1. Be on page 1 and navigate to page 2
  2. Play the video
  3. Toggle Fullscreen
  4. Toggle Back Button on your device
  5. Page 1 is now active in background, while mediaElement is still in foreground fulscreen

Link to public reproduction project repository

https://github.com/South2AK/MediaElementBackButtonBug

Environment

- .NET MAUI CommunityToolkit:3.1.0
- OS:Android API 33 / 34
- .NET MAUI: 8

Anything else?

Also, if the page has been added via AddTransient, the page crashes since the MediaELement has been disposed of

@South2AK South2AK added bug Something isn't working unverified labels Mar 14, 2024
@vhugogarcia vhugogarcia added the 📽️ MediaElement Issue/PR that has to do with MediaElement label Mar 16, 2024
@ne0rrmatrix
Copy link
Contributor

@South2AK can you check if the linked PR fixes your issue? Thank you for taking the time to file the report.

@South2AK
Copy link
Author

South2AK commented Apr 8, 2024

@ne0rrmatrix Hi,

the pr works, BUT hopefully you don´t get me wrong..

Wouldn´t it be better if the back button just simply toggles the fullscreen button without stopping playback and also stopping the Page Go back Behavior?

A perfect behavior would be:
Full Screen is on --> Back button pressed --> Full Screen is off (Page where MediaElement is displayed is still on and also Player is still playing) --> Back Button is pressed a second time --> Page goes back

Thank you :)

@ne0rrmatrix
Copy link
Contributor

I just fixed the behavior. It no longer overrides the default behavior. It just exits full screen on back button pressed now. It does nothing else. Thank you testing and providing insight into behavior. That PR is to fix an issue with full screen not going back to normal mode when back button is pressed. If you want the behavior changed I suggest opening a discussion about adding a feature/proposal.

@South2AK
Copy link
Author

South2AK commented Apr 8, 2024

Thank you @ne0rrmatrix

How can I test it? Has the PR been changed?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working 📽️ MediaElement Issue/PR that has to do with MediaElement unverified
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants