When ArcProgress is 0, diagonal lines show on iOS
Opened this issue · 0 comments
schreiby commented
Hello,
I posted this in the CN1CircleProgress issue tracker, but was advised to post it here as well, so I apologize for the duplicate posts.
I noticed that when the ArcProgress is set to 0 on iOS, diagonal lines show near the starting point. Sometimes, those lines don't show on the first load, but after reopening the app, the lines will show. I have not been able to replicate this on the Simulator or Android.
Lianna suggested that I use this as a workaround:
protected String formattedValue(int value) {
if(value == 1 && fakeZero) value = 0;
return super.formattedValue(value);
}
I actually got around this by extending ArcProgress and overriding the following methods so that 1% should be displayed on the ArcProgress, but the text should say 0%:
@Override
public void setProgress(int value) {
if (value == 0)
value = 1;
super.setProgress(value);
}
@Override
protected String formattedValue(int value) {
if (value == 1)
value = 0;
return super.formattedValue(value);
}
Once there's at least 1% progress, the lines don't show anymore.