在 RES /值-V11 / styles.xml
,我不能使用 Theme.Holo.Light.NoActionBar
,因为它被添加在API层面13.我可以使用 Theme.Light.NoTitleBar
相反,没有视觉上的差异?据我所知,他们都应该有一个白色的背景,现状和导航栏,而不是其他。
In res/values-v11/styles.xml
, I can't use Theme.Holo.Light.NoActionBar
because it was added in API level 13. Can I use Theme.Light.NoTitleBar
instead, with no visual differences? As far as I can tell, they should both have a white background, status and navigation bars, and nothing else.
推荐答案
Theme.Light.NoTitleBar略有不同。解决这个并保持兼容回到蜂巢的最简单的方法是创建你自己的风格,扩展Theme.Holo.Light,但删除操作栏。只要创建一个风格的定义如下:
Theme.Light.NoTitleBar is slightly different. The easiest way to resolve this and stay compatible back to Honeycomb is to create your own style that extends Theme.Holo.Light, but removes the Action Bar. Just create a style with the following definition:
<style name="MyTheme" parent="android:Theme.Holo.Light">
<item name="android:windowActionBar">false</item>
<item name="android:windowNoTitle">true</item>
</style>
相关推荐
最新文章