代码里面设置颜色
this.getResources().getColor(R.color.Login_title_bar)
用法:
1 title.setTextColor(this.getResources().getColor(R.color.white)); 2 layout.setBackgroundColor(this.getResources().getColor(R.color.Login_title_bar));
代码里面设置背景图片
1 this.getResources().getDrawable(R.drawable.download_button)
用法
1 holder.mRoundProgressBar.setBackground(context.getResources().getDrawable(R.drawable.download_button));