Before someone marks this as a duplicate, I've spent hours looking through google and StackOverflow for answers to my problem and have not found any.
I've used the Android Studio Login Activity but I can't get the title bar to go away in that one activity (not the whole app). I've read over at least 10 different articles on how to do this, most of them say the same thing and none of it works. In fact, editing my .java class crashes my app. Is there a relation to this and the pre-built code involved in the Login Activity?
I've tried the following blocks of code in different orders in one of my java files:
getWindow().setFlags(WindowManager.LayoutParams.FLAG_FULLSCREEN,
WindowManager.LayoutParams.FLAG_FULLSCREEN);this.getWindow().setFlags(WindowManager.LayoutParams.FLAG_FULLSCREEN, WindowManager.LayoutParams.FLAG_FULLSCREEN); requestWindowFeature(Window.FEATURE_NO_TITLE);
this.requestWindowFeature(Window.FEATURE_NO_TITLE);
I've tried setting the NoActionBar theme in my XML file, as well as adding to the Manifest (which I don't want to do because that blankets the app... I just want the one page (login)'s title bar to go away.
I've tried everything that I could find on here and on google's search. Has anyone else ran into this problem while using the Login Activity in Studio?
Also, I found this answer -
"You should use 'NoActionBar' Style in 'styles.xml'. Than create toolbar in your layout and add child view to your toolbar, set title and modify as you like. "
- This also does not work. I found that answer here: StackOverflow
Still no luck. I'd appreciate any advice. Thanks for your time!
EDIT: Someone told me to delete the ActionBar Class:
private void setupActionBar() { ActionBar actionBar = getSupportActionBar(); if (actionBar != null) { actionBar.setDisplayHomeAsUpEnabled(true); setupActionBar(); } }
Also deleted the call to actionBar. -- This also did not work.
I found this topic on Stack: Android Theme.TitleBar does not work This was not helpful at all.
I tried this topic too which was also useless: How to hide the title bar for an Activity in XML with existing custom theme
