a few changes of Android 5.0

原文链接:http://www.cnblogs.com/ZacharyHodgeZou/p/4604434.html

1.Service Intent must be explicit

Intent serviceIntent = new Intent(context,MyService.class);
context.startService(serviceIntent);
Note:Implicit intents with startService are not safe

2.Button Text is always Uppercase

<style name="TextAppearance.Material.Button">
<item name="textSize">@dimen/text_size_button_material</item>
<item name="fontFamily">@string/font_family_button_material</item>
<item name="textAllCaps">true</item>
<item name="textColor">?attr/textColorPrimary</item>
</style>

Using <item name="android:textAllCaps">false</item>

3.Material Design Action Bar 默认是有shadow的,是因为新的elevation API,

action bar style 的xml中,定义elevation 属性为0

or getActionBar().setElevation(0)

转载于:https://www.cnblogs.com/ZacharyHodgeZou/p/4604434.html

上一篇:21206125-孙琪-九月二十日 python学习总结(三)


下一篇:计算机二级python自主复习其四——函数和代码复用