From 0a34ec573c0492205c3de30daa84c596e9564de3 Mon Sep 17 00:00:00 2001 From: Ian Jackson Date: Mon, 13 Jun 2022 00:57:43 +0100 Subject: [PATCH] script: Make mouse cursor different in wresting mode Signed-off-by: Ian Jackson --- templates/script.ts | 21 ++++++++++++++++++++- 1 file changed, 20 insertions(+), 1 deletion(-) diff --git a/templates/script.ts b/templates/script.ts index b6a77414..e28b4dd5 100644 --- a/templates/script.ts +++ b/templates/script.ts @@ -548,7 +548,26 @@ function mousecursor_etc_reupdate() { let xy; let path = 'stroke-linecap="square" d="M -10 -10 10 10 M 10 -10 -10 10"'; - if (special_count == null) { + if (wresting) { + let text; + if (special_count == null) { + text = "WREST"; + } else if (special_count == 0) { + text = "W v"; + } else { + text = "W " + special_count; + } + xy = '60 15'; + svg = +` + + + + ${text} + `; + } else if (special_count == null) { } else { if (special_count != 0) { let text_len = special_count.toString().length; -- 2.30.2