How to hide action bar for fragment?

前端 未结 9 1317
挽巷
挽巷 2021-01-31 08:17

How can I hide action bar for certain fragment? I have searched for the answer at stackoverflow, but I have only found a solution, which involves disabling action bar for main a

9条回答
  •  你的背包
    2021-01-31 09:04

    Have you tried getActivity().getSupportActionBar().hide() in the onCreate() of the fragment you wish the ActionBar to be hidden in?

    I am assuming you are not using ActionBarSherlock.

提交回复
热议问题