FloatingActionButton doesn't hide

后端 未结 17 955
星月不相逢
星月不相逢 2020-11-30 03:42

I am trying to hide my FloatingActionButton fabLocation programmatically with :

fabLocation.setVisibility(View.GONE)

but it do

17条回答
  •  青春惊慌失措
    2020-11-30 04:24

    The most simplistic way to hide and show a floating action button would be to call this in your activity. This will also properly animate your FAB automatically.

    Hide:

    nameOfYourFAB.Hide();
    

    Show:

    nameOfYourFAB.Show();
    

提交回复
热议问题