我有以下 XML:
<layer-list xmlns:android="http://schemas.android.com/apk/res/android">
<item android:id="@+id/customPlayerProgressBg">
<shape>
<gradient
android:startColor="#FF999999"
android:endColor="#FF999999"
/>
</shape>
</item>
<item android:id="@+id/customPlayerProgressSecondary">
<clip>
<shape>
<gradient
android:startColor="#FF5C3C68"
android:endColor="#FF5C3C68"
/>
</shape>
</clip>
</item>
<item
android:id="@+id/customPlayerProgress"
>
<clip>
<shape>
<gradient
android:startColor="#FF5C3C68"
android:endColor="#FF5C3C68"
/>
</shape>
</clip>
</item>
</layer-list>
我想通过 Java 代码更改“customPlayerProgress”和“customPlayerProgressSecondary”。那怎么能做到呢?