From 9545fc76bb31a7c0b51df153849147b3c6db6a8e Mon Sep 17 00:00:00 2001 From: Rufo Sanchez Date: Sat, 23 Jan 2021 16:38:53 -0600 Subject: [PATCH] Reduce CPU utilization of progress circle The value of the math progress circle winds up calculating progress to an incredibly fine degree, which causes hundreds of updates and recalculations. Changing the progress circle to round to the closest percentage greatly reduces the number of updates, dropping the browser's CPU usage by 10-20%. --- src/components/panels/StatusPanel.vue | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/components/panels/StatusPanel.vue b/src/components/panels/StatusPanel.vue index 0df41728..7a0d07f9 100644 --- a/src/components/panels/StatusPanel.vue +++ b/src/components/panels/StatusPanel.vue @@ -71,7 +71,7 @@ :rotate="-90" :size="50" :width="7" - :value="printPercent * 100" + :value="Math.round(printPercent * 100)" color="red" >