实现Android的Gmail的平板电脑设计的选择(箭头样式) [英] Achieve android gmail tablet design in selection (arrow style)
问题描述
我想建立一个平板电脑优化的应用程序,我想跟随Gmail的平板版本中选择相同的风格(右侧的选择的箭头)。我不知道如何获得相同的风格。有阴影和箭头的选择
I am trying to build a tablet optimized app and I would like to follow the same style of gmail tablet version in selections (the arrow on the right side of the selection). I don't know how to obtain the same style. There is a shadow and an arrow for the selection.
这是Gmail应用程序图像:
This is an image of gmail app:
感谢
推荐答案
箭头是列表项的背景的一部分。
The arrow is just part of the list item background.
下面是和例如,从电子邮件应用程序,其中list_selected_holo是包含在其右侧的箭头被拉伸(您可以用简单的谷歌搜索被拉伸)。
Here is and example from the Email application where list_selected_holo is a drawable that contains an arrow on its right side (You can find the drawable with simple google search).
<selector xmlns:android="http://schemas.android.com/apk/res/android">
<item android:state_pressed="true"
android:drawable="@drawable/list_pressed_holo" />
<item android:state_focused="true"
android:drawable="@drawable/list_focused_holo" />
<item android:state_selected="true"
android:drawable="@drawable/list_selected_holo" />
<item android:drawable="@drawable/list_read_holo" />
</selector>
我建议在看开源电子邮件应用程序,它目前的股票风格的Gmail应用程序。裁判: https://github.com/android/platform_packages_apps_email 请注意,它需要从外部路径的一些资源,我找不到在github(框架的/ opt / mailcommon / RES)。
I would suggest looking at the open source Email application which now shares style with the Gmail application. ref: https://github.com/android/platform_packages_apps_email Note that it takes some resources from external path which I couldn't find on github (frameworks/opt/mailcommon/res).
这篇关于实现Android的Gmail的平板电脑设计的选择(箭头样式)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!