-
-
Notifications
You must be signed in to change notification settings - Fork 2.9k
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
chore(android): remove onBackPressed function in FullScreenPlayerView #4049
chore(android): remove onBackPressed function in FullScreenPlayerView #4049
Conversation
@seyedmostafahasani correct me if I am wrong but this should fix #4047 ? |
I think this PR can resolve it. |
What happens if the user does not press the system back button but they press a button that invokes |
@sntg-p I just want to be sure that I get you correctly. For full-screen mode you navigate to another screen and use the prop |
This is currently not working properly as I mentioned in #4047. Not really sure if this PR fixes that, as I didn't test it. |
@sntg-p would you please share your code with me if it's possible or sample of your code? |
That's exactly i am using and then statusbar and navbar gets hidden |
I think there is a side effect here. If you go to full screen, leave the app (press home), and go back to the app, full screen will be dismissed as onStop has been called. |
i tried it on my app and fullscreen stays |
I tested your scenario, and the app works correctly. I pressed the home button, then I went back to the app, but the app was in full-screen mode. |
@mkbhdana |
well setFullscreen also not resolved my issue i just used react-native-system-navigation-bar this library and calling SystemNavigationBar.fullScreen(false); on onBack handler and this solves my entire problem with status and navigation bar while keeping fullscreen={true} in react native video component |
@sntg-p also I find if I keep fullscreen = true then then navigation bar adds some space above it after dismissing video so to solve it I set fullscreen = false in video commponent and instead I use SystemNavigationBar.fullScreen(true); and SystemNavigationBar.immersive(); inside useEffect so it helped to resolve the issue. |
@KrzysztofMoch |
@seyedmostafahasani I fix conflicts manually, can you double it is still working on your side and we can merge ? |
@freeboub |
Summary
Removed the onBackPressed function.
Motivation
I fixed a potential issue where the
setFullscreen
method was not being called if the user did not press the back button.fix #4047, #4057
Changes
Test plan