[英]Why doesn't android:colorBackground work on some devices?
<resources>
<style name="Theme.MyApplication" parent="Theme.MaterialComponents.Light">
<item name="android:colorBackground">#26A69A</item>
</style>
</resources>
I want to know why android:colorBackground
doesn't work on some devices.我想知道为什么android:colorBackground
在某些设备上不起作用。 I ran the app on the API 21 (Not working)
, 24 (Not Working)
, and 29 (Working)
.我在 API 21 (Not working)
、 24 (Not Working)
和29 (Working)
上运行了该应用程序。
It's working now after I changed it like this在我这样更改后它现在可以工作了
<resources>
<style name="Theme.MyApplication" parent="Theme.MaterialComponents.Light">
<item name="android:colorBackground">@color/myColor</item>
</style>
</resources>
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.