define variables

pull/3519/head
Ian Ward 2024-07-20 19:52:36 +01:00
parent f520a8ae7b
commit 2b6839bedb
1 changed files with 4 additions and 4 deletions

View File

@ -91,10 +91,10 @@
// Draw hour or minute boxes
let drawBox = function drawBox(current, boxes, size, colour) {
x1 = (boxes[current].x * Bangle.appRect.h) + (Bangle.appRect.y/2);
y1 = (boxes[current].y * Bangle.appRect.h) + Bangle.appRect.y;
x2 = x1 + size;
y2 = y1 + size;
let x1 = (boxes[current].x * Bangle.appRect.h) + (Bangle.appRect.y/2);
let y1 = (boxes[current].y * Bangle.appRect.h) + Bangle.appRect.y;
let x2 = x1 + size;
let y2 = y1 + size;
g.setColor(colour);
g.fillRect(x1, y1, x2, y2);
};