speechles 2055 Posted July 23, 2024 Posted July 23, 2024 (edited) Standard Android app - top statusbar and bottom taskbar stays visible Android TV app - both statusbar and taskbar are hidden Android 13 introduces this taskbar which hides during fullscreen playback but does not hide during fullscreen navigation on the standard android app. Is there some way to copy what Android TV does to hide both these bars during navigation? Edited July 23, 2024 by speechles 1
Luke 42077 Posted July 24, 2024 Posted July 24, 2024 HI, it's the TV app that is actually functioning incorrectly here. There isn't a Fullscreen button outside of playback. Not currently at least. Did you try double clicking the header? I don't recall off the top of my head if we've implemented that on android or not.
speechles 2055 Posted July 24, 2024 Author Posted July 24, 2024 @Lukehttps://developer.android.com/develop/ui/views/layout/immersive Specify which system bars to hide To specify the type of system bars to hide, pass one of the following parameters to WindowInsetsControllerCompat.hide(). Use WindowInsetsCompat.Type.systemBars() to hide both system bars. Use WindowInsetsCompat.Type.statusBars() to hide only the status bar. Use WindowInsetsCompat.Type.navigationBars() to hide only the navigation bar.
Luke 42077 Posted July 24, 2024 Posted July 24, 2024 6 minutes ago, speechles said: @Lukehttps://developer.android.com/develop/ui/views/layout/immersive Specify which system bars to hide To specify the type of system bars to hide, pass one of the following parameters to WindowInsetsControllerCompat.hide(). Use WindowInsetsCompat.Type.systemBars() to hide both system bars. Use WindowInsetsCompat.Type.statusBars() to hide only the status bar. Use WindowInsetsCompat.Type.navigationBars() to hide only the navigation bar. Right, if we had a button to enter that mode, but it shouldn't open up by default and cover the system task bar.
speechles 2055 Posted July 24, 2024 Author Posted July 24, 2024 (edited) 7 minutes ago, Luke said: Right, if we had a button to enter that mode, but it shouldn't open up by default and cover the system task bar. It should open up by default if the app is in fullscreen mode when it launches. That is entirely the point of immersive mode. There is no need for a button. All bars get hidden. Once the user isn't using what the device detects as the fullscreen resolution you can add the bars back. That way even split-screen would work. Since the resolution is detected at whatever the split is. Every other app works this way without a button. I am curious why would you think you would need a button? Right now the bars are just omnipresent all the time making Android TV look more attractive in fullscreen. --- Specify behavior of hidden system bars Use WindowInsetsControllerCompat.setSystemBarsBehavior() to specify how hidden system bars behave when the user interacts with them. Use WindowInsetsControllerCompat.BEHAVIOR_SHOW_BARS_BY_TOUCH to reveal hidden system bars on any user interactions on the corresponding display. Use WindowInsetsControllerCompat.BEHAVIOR_SHOW_BARS_BY_SWIPE to reveal hidden system bars on any system gestures, such as swiping from the edge of the screen where the bar is hidden from. Use WindowInsetsControllerCompat.BEHAVIOR_SHOW_TRANSIENT_BARS_BY_SWIPE to temporarily reveal hidden system bars with system gestures, such as swiping from the edge of the screen where the bar is hidden from. These transient system bars overlay your app’s content, might have some degree of transparency, and are automatically hidden after a short timeout. It would be easy to get them to appear with a screen tap or swipe or however you wanted users to interact to bring it back. But it shouldn't be a button. WindowInsetsControllerCompat.BEHAVIOR_SHOW_TRANSIENT_BARS_BY_SWIPE The above would be the most intutive way to handle the bars if users want to interact with them. Swipe down from absolute top (say the highest 50 pixels) the system bar shows. Swipe up from absolute bottom (say the lowest 50 pixels) the system bar/navigation bar shows up. Edited July 24, 2024 by speechles
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now