码迷,mamicode.com
首页 > 移动开发 > 详细

a few changes of Android 5.0

时间:2015-06-27 19:50:52      阅读:132      评论:0      收藏:0      [点我收藏+]

标签:

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)

a few changes of Android 5.0

标签:

原文地址:http://www.cnblogs.com/ZacharyHodgeZou/p/4604434.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!