I want to hide the titlebar for some of my activities. The problem is that I applied a style to all my activities, therefore I can\'t simply set the theme to @android:
the correct answer probably is to not extend ActionbarActivity rather extend just Activity
if you still use actionbar activity seems this is working:
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
getSupportActionBar().hide(); //<< this
setContentView(R.layout.activity_main);
}
seems this works too:
styles.xml:
i could do like as Scott Biggs wrote. this kind of works. except there is no theme then. i mean the settings menu's background is transparent:
just change
public class MainActivity extends ActionBarActivity {
to Activity or FragmentActivity
public class MainActivity extends Activity {
however i could make it look good enough using material design and not remove the actionbar: https://gist.github.com/shimondoodkin/86e56b3351b704a05e53
it is by example of material design compatibility actionbar styling.