progress: limit value to 100

This commit is contained in:
Raphael Coeffic
2022-07-03 07:16:46 +02:00
parent 0d8b36a0cf
commit 6b1ca16c7f
+2 -1
View File
@@ -22,5 +22,6 @@
void Progress::paint(BitmapBuffer * dc)
{
theme->drawProgressBar(dc, 0, 0, width(), height(), value, 100);
auto val = value > 100 ? 100 : value;
theme->drawProgressBar(dc, 0, 0, width(), height(), val, 100);
}