Stefan4472 / GalaxyRun

A space-themed infinite runner for Android
GNU General Public License v3.0
0 stars 0 forks source link

Hide Navbar #137

Closed Stefan4472 closed 2 years ago

Stefan4472 commented 2 years ago

Hide the Navbar (buttons at the bottom of the screen) in MainActivity and in GameActivity

Stefan4472 commented 2 years ago

https://developer.android.com/training/system-ui/navigation

Stefan4472 commented 2 years ago

Turns out it isn't straightforward to get this right.

Stefan4472 commented 2 years ago

Found a nice solution, which is to make the navbar transparent, but leave it there.

When the navbar was hidden, the problem was that any screen touch close to that side of the screen would trigger the nav bar to show. That caused the GameView to change size and was very disruptive.