windowBackground和android:colorBackground机器人之间的区别? [英] Difference between android:windowBackground and android:colorBackground?

查看:2226
本文介绍了windowBackground和android:colorBackground机器人之间的区别?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

什么是机器人之间的区别:windowBackground 安卓?colorBackground

例如:

<style name = "theme">
 <item name ="android:windowBackground">@color/black</item>
 <item name ="android:colorBackground">@color/black</item>
</style>

哪一个会影响你看,当一个新的活动正在加载颜色?

Which one would effect the color you see when a new activity is loading?

推荐答案

windowBackground只会影响你的主窗口的背景。但colorBackground影响血糖不仅对主窗口,而且对所有的组件,例如对话框,除非你覆盖它在你的元件布局。 所以,他们都改变你的活动的BG,但后者改变很多事情也是如此。

windowBackground only affects your main window background. But colorBackground affects the bg not only for the main window, but for all your components e.g. dialogs unless you override it in your component layout. So both of them change your activity's bg, but the latter changes many more things as well.

这篇关于windowBackground和android:colorBackground机器人之间的区别?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆