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

android r.styleable是什么或报错

时间:2015-07-01 20:07:44      阅读:177      评论:0      收藏:0      [点我收藏+]

标签:

r.styleable 是自定义控件

自定义控件写好的后,需要在
res-value-attrs.xml中定义,如:

 1 <declare-styleable name="SlidingMenu">
 2         <attr name="mode">
 3             <enum name="left" value="0" />
 4             <enum name="right" value="1" />
 5         </attr>
 6         <attr name="viewAbove" format="reference" />
 7         <attr name="viewBehind" format="reference" />
 8         <attr name="behindOffset" format="dimension" />
 9         <attr name="behindWidth" format="dimension" />
10         <attr name="behindScrollScale" format="float" />
11         <attr name="touchModeAbove">
12             <enum name="margin" value="0" />
13             <enum name="fullscreen" value="1" />
14         </attr>
15         <attr name="touchModeBehind">
16             <enum name="margin" value="0" />
17             <enum name="fullscreen" value="1" />
18         </attr>
19         <attr name="shadowDrawable" format="reference" />
20         <attr name="shadowWidth" format="dimension" />
21         <attr name="fadeEnabled" format="boolean" />
22         <attr name="fadeDegree" format="float" />
23         <attr name="selectorEnabled" format="boolean" />
24         <attr name="selectorDrawable" format="reference" />
25     </declare-styleable>

 

android r.styleable是什么或报错

标签:

原文地址:http://www.cnblogs.com/jenson138/p/4613847.html

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