From f24b05a7be99b6cd2ae90d641b280c2ba7ef3623 Mon Sep 17 00:00:00 2001 From: Luis Fernando Molina Date: Sat, 19 Oct 2019 12:27:21 +0200 Subject: [PATCH] Show shortcut key with crtl --- Canvas.js | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/Canvas.js b/Canvas.js index fc63decf1..3475ecff0 100644 --- a/Canvas.js +++ b/Canvas.js @@ -286,8 +286,14 @@ function newCanvas () { nodeOnFocus.payload.uiObject.shortcutKey = event.key nodeOnFocus.payload.uiObject.setValue('Shortcut Key: Ctrl + ' + event.key) } + return + } + } + + if (event.ctrlKey === true && nodeOnFocus !== undefined) { + if (nodeOnFocus.payload.uiObject.shortcutKey !== undefined && nodeOnFocus.payload.uiObject.shortcutKey !== '') { + nodeOnFocus.payload.uiObject.setValue('Shortcut Key: Ctrl + ' + nodeOnFocus.payload.uiObject.shortcutKey) } - return } }