Remove up button from action bar when navigating using BottomNavigationView with Android Navigation UI library

后端 未结 6 785
时光取名叫无心
时光取名叫无心 2021-02-01 04:29

I\'ve created a small app that has three fragments for top-level navigation through a BottomNavigationView. If you launch the app and click on a navigation button on the bottom

6条回答
  •  暖寄归人
    2021-02-01 05:11

    If you are using NavigationUI.setupWithNavController check out onNavDestinationSelected.

    Inside your bottom navigation view menu.xml, add android:menuCategory="secondary" to the corresponding MenuItem:

    
    
    
      
    

提交回复
热议问题