Skip to content

Commit

Permalink
small removal
Browse files Browse the repository at this point in the history
  • Loading branch information
MerinoSheep committed Feb 19, 2025
1 parent 7adf7bc commit 2df9ac6
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions DIM/Src/tftDL.c
Original file line number Diff line number Diff line change
Expand Up @@ -188,7 +188,7 @@ static void tftDL_barSetY(const tftDL_vert_bar_t *bar, uint32_t val) {
} else if (val > bar->maxVal) {
y = bar->topY;
} else {
uint32_t len = ((val - bar->minVal) * (uint32_t)(bar->botY - bar->topY)) / (bar->maxVal - bar->minVal);
uint32_t len = ((val - bar->minVal) * (bar->botY - bar->topY)) / (bar->maxVal - bar->minVal);
y = bar->botY - len;
}

Expand All @@ -215,7 +215,7 @@ static void tftDL_barSetX(const tftDL_horiz_bar_t *bar, uint32_t val) {
} else if (val > bar->maxVal) {
x = bar->rightX;
} else {
uint32_t len = ((val - bar->minVal) * ((uint32_t)(bar->rightX - bar->leftX))) / (bar->maxVal - bar->minVal);
uint32_t len = ((val - bar->minVal) * (bar->rightX - bar->leftX)) / (bar->maxVal - bar->minVal);
x = bar->leftX + len;
}

Expand Down

0 comments on commit 2df9ac6

Please sign in to comment.