android:background="@drawable/shape_daily_spike_bg_blue"
改变背景颜色可以这么做:
GradientDrawable bgShape = (GradientDrawable)mView.getBackground();
bgShape.setColor();
android:background="@drawable/shape_daily_spike_bg_blue"
改变背景颜色可以这么做:
GradientDrawable bgShape = (GradientDrawable)mView.getBackground();
bgShape.setColor();
本文标题:代码中改变shape的颜色
本文链接:https://www.haomeiwen.com/subject/dzglrttx.html
网友评论