widhid: only draw if width > 0 (i.e. when connected)

pull/2734/head
Rob Pilling 2023-05-08 15:07:42 +01:00
parent 69bfcfeb99
commit 0192b150e7
2 changed files with 3 additions and 0 deletions

View File

@ -95,6 +95,8 @@
area: "tr",
sortorder: -20,
draw: function () {
if (this.width === 0)
return;
g.drawImage(activeTimeout
? require("heatshrink").decompress(atob("jEYxH+AEfH44XXAAYXXDKIXZDYp3pC/6KHUMwWHC/4XvUy4YGdqoA/AFoA=="))
: require("heatshrink").decompress(atob("jEYxH+AEcdjoXXAAYXXDKIXZDYp3pC/6KHUMwWHC/4XvUy4YGdqoA/AFoA==")), this.x + 2, this.y + 2);

View File

@ -96,6 +96,7 @@
area: "tr",
sortorder: -20,
draw: function() {
if(this.width === 0) return;
g.drawImage(
activeTimeout
? require("heatshrink").decompress(atob("jEYxH+AEfH44XXAAYXXDKIXZDYp3pC/6KHUMwWHC/4XvUy4YGdqoA/AFoA=="))