pace: drop lazyUnlazy
parent
5c9a4aed62
commit
ca1cb2253a
|
|
@ -13,7 +13,6 @@ const exs = require("exstats").getStats(
|
||||||
);
|
);
|
||||||
|
|
||||||
let drawTimeout: TimeoutId | undefined;
|
let drawTimeout: TimeoutId | undefined;
|
||||||
let lastUnlazy = 0;
|
|
||||||
|
|
||||||
const splits: number[] = []; // times
|
const splits: number[] = []; // times
|
||||||
let splitOffset = 0, splitOffsetPx = 0;
|
let splitOffset = 0, splitOffsetPx = 0;
|
||||||
|
|
@ -85,9 +84,6 @@ const draw = () => {
|
||||||
layout["time"]!.label = formatDuration(exs.state.duration);
|
layout["time"]!.label = formatDuration(exs.state.duration);
|
||||||
layout["pace"]!.label = pace;
|
layout["pace"]!.label = pace;
|
||||||
layout.render();
|
layout.render();
|
||||||
|
|
||||||
if (now - lastUnlazy > 30000)
|
|
||||||
layout.forgetLazyState(), lastUnlazy = now;
|
|
||||||
};
|
};
|
||||||
|
|
||||||
const pad2 = (n: number) => `0${n}`.substr(-2);
|
const pad2 = (n: number) => `0${n}`.substr(-2);
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue