Android 去掉titlebar
阿新 • • 發佈:2018-11-09
只需要將預設的styles.xml
修改成<resources>
<!-- Base application theme. -->
<style name=“AppTheme” parent=“Theme.AppCompat.Light.DarkActionBar”>
<!-- Customize your theme here. -->
<item name=“colorPrimary”>@color/colorPrimary</item>
<itemname=“colorPrimaryDark”>@color/colorPrimaryDark</item>
<item name=“colorAccent”>@color/colorAccent</item>
</style>
</resources>
<resources>
<!-- Base application theme. -->
<style name=“AppTheme” parent=“Theme.AppCompat.Light.NoActionBar”>
<!-- Customize your theme here. -->
<item name=“colorPrimary”>@color/colorPrimary</item>
<item name=“colorPrimaryDark”>@color/colorPrimaryDark</item>
<item name=“colorAccent”>@color/colorAccent</item>
</style>
</resources>