Minor tweak - avoid flicker when date is rendered again after minutes slides off

pull/2216/head
Gordon Williams 2022-11-02 16:37:40 +00:00
parent ee1675d5f0
commit 219fe891af
1 changed files with 6 additions and 7 deletions

View File

@ -90,11 +90,10 @@ let animate = function(isIn, callback) {
if (stop) {
clearInterval(animInterval);
animInterval=undefined;
if (isAnimIn) // draw the date
g.setColor(g.theme.bg).setFontAlign(0, 0).setFont("6x15").drawString(dateStr, R.x + R.w/2, R.y+R.h-9);
if (callback) callback();
if (isAnimIn) {
// draw the date
g.setColor(g.theme.bg).setFontAlign(0, 0).setFont("6x15").drawString(dateStr, R.x + R.w/2, R.y+R.h-9);}
}
}
}, 20);
};