I have some troubles trying to remove a toolbar in a specific fragment, i have this code in onCreateView fragment method:
public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {
View view = inflater.inflate(R.layout.fragment_login,container,false);
mValidator = new Validator(this);
mValidator.setValidationListener(this);
mFbHelper = new
mGHelper = new GoogleHelper(this, null, this);
((DrawerUtil) getActivity()).setDrawerLocked(true);
((AppCompatActivity) getActivity()).getSupportActionBar().hide();
initViews(view);
return view;
}
I can hide the ActionBar, but the idea is to remove the ActionBar to use properly a logo, im using this code: ((AppCompatActivity) getActivity()).getSupportActionBar().setDisplayHomeAsUpEnabled(state);
but it doesnt work.
Any ideas?