ITeye博客

android textview 代码设置颜色状态

hkk · 2012-05-14 14:33 · android应用实践 · 移动开发 · Markdown

try {
   Resources resource = (Resources) getResources();
   ColorStateList csl = (ColorStateList) resource
     .getColorStateList(R.color.qianqubtnselector);
   btn.setTextColor(csl);
  } catch (Exception e) {
  }

代码设置颜色

评论(0)

暂无评论。

评论功能维护中,当前仅展示历史评论。