【发布时间】:2023-04-04 22:00:01
【问题描述】:
我在样式中的默认色调重音颜色是蓝色,如果发生错误,我会像下面的代码一样以编程方式将其更改为红色
Drawable wrappedDrawable = DrawableCompat.wrap(mUsername.getBackground());
DrawableCompat.setTint(wrappedDrawable, ContextCompat.getColor(getActivity(), R.color.red_error));
但是当我重新启动我的应用程序时,色调颜色为红色,我如何将其设置回 style.xml 中的默认颜色?
【问题讨论】:
标签: android android-edittext material-design textinputlayout