4

Is it possible to change system navigation to gesture or 3-button navigation programmatically?

3
  • I know hiding gesturebar systemwide is possible within the phone. I know changing systemwide navigation programatically is possible using ADB. But I've never heard of a method of doing it within the phone like hiding gesturebar. Even if you find a way to do it, you shouldn't use it if you're going to release your app publicly. Commented Jun 24, 2021 at 23:36
  • @Shazniq Adb could also help me actually. Do you know the commands? Commented Jun 25, 2021 at 8:17
  • @tomas I've updated my answer with the adb commands Commented Jun 25, 2021 at 15:37

2 Answers 2

11

This is not supported currently.

You can't change navigation in behalf of user. This is an important user preference and enabling apps to change the system navigation type would create confusion only. I don't think it will ever be supported.

Moreover there is no action here to even "guide" the user to the specific settings screen

On some devices this can be changed with adb commands (but there is no warranty those commands will work in future)

//Enable gesture navigation
adb shell cmd overlay enable com.android.internal.systemui.navbar.gestural

//Enable 2-button navigation
adb shell cmd overlay enable com.android.internal.systemui.navbar.twobutton

//Enable 3-button navigation
adb shell cmd overlay enable com.android.internal.systemui.navbar.threebutton
Sign up to request clarification or add additional context in comments.

Comments

2

Disabling navbar by

cmd overlay enable com.android.internal.systemui.navbar.gestural

works well but enabling it back doesnt change ui size so some elements of programs ui (bottom bar) could be overlayed by navbar. To fix it i found a trick. To enable it use

cmd overlay disable com.android.internal.systemui.navbar.gestural
cmd overlay enable com.android.internal.systemui.navbar.threebutton

Comments

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.