1

I'm trying to hide my android default navigation bar. I'm using SystemChrome on my main.dart :

void main() async {
  SystemChrome.setEnabledSystemUIOverlays([SystemUiOverlay.top]);
  ...

But whenever I'm touching my screen the navigation bar appears again.

On the other hand, when I'm hiding both top and bottom using:

void main() async {
  SystemChrome.setEnabledSystemUIOverlays([]);
  ...

They are both permanently remove.

I need to remove only the bottom navigation bar. What is the problem? How can I fix that?

Thanks

genericUser
  • 4,417
  • 1
  • 28
  • 73

1 Answers1

0

Try using SystemChrome.setEnabledSystemUIMode instead of SystemChrome.setEnabledSystemUIOverlays

example:

SystemChrome.setEnabledSystemUIMode(
  SystemUiMode.manual,
  overlays: [SystemUiOverlay.top],
);