Basically i have a circular progress bar and i have set a style to it, but the color does not change at all, its just green the whole time.
Code:
<ProgressBar
android:id="@+id/markAssistedProgressLayout"
android:visibility="gone"
style="@style/progressBarWhite"
android:layout_width="50dp"
android:layout_height="50dp" />
Style file:
<style name="progressBarWhite" parent="@style/Theme.AppCompat">
<item name="colorAccent">@color/cherry_red_10_percent_opacity</item>
</style>
The pic:
Hope someone could help me.
Rather than using a style, i directly set a indeterminateTint.
<ProgressBar
android:id="@+id/markAssistedProgressLayout"
android:visibility="gone"
android:layout_width="50dp"
android:layout_height="50dp"
android:indeterminateTint="@color/white"/>
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.