【发布时间】:2017-01-25 16:42:07
【问题描述】:
我有一个启动画面和其他活动。
我的想法是我希望启动屏幕是全屏的,并且所有其他活动都像往常一样有一个标题栏和一个 ActionBar。
我在styles.xml文件中设置了2个样式
<!-- Base application theme. -->
<style name="AppTheme" parent="Theme.AppCompat.Light.DarkActionBar">
<!-- Customize your theme here. -->
<item name="colorPrimary">@color/colorPrimary</item>
<item name="colorPrimaryDark">@color/colorPrimaryDark</item>
<item name="colorAccent">@color/colorAccent</item>
</style>
<!-- Splash theme. -->
<style name="Splash" parent="@style/Theme.AppCompat.Light">
<item name="windowNoTitle">true</item>
<item name="windowActionBar">false</item>
<item name="android:windowFullscreen">true</item>
<item name="android:windowContentOverlay">@null</item>
</style>
然后在我放的清单文件中
android:theme="@style/AppTheme"
在那之后,我迷路了:我尝试将样式和/或主题设置为在 xml 代码中为 splashScreen 使用“Splash”,但它不起作用
设置manifest style会改变所有app的Activity,我只想改变一个
任何帮助将不胜感激。
【问题讨论】:
标签: android android-theme