From aa899b809697c680c806544c612e389902a65c70 Mon Sep 17 00:00:00 2001 From: antelle Date: Sat, 23 May 2020 17:07:59 +0200 Subject: [PATCH] fix #1409: fixed auto-typing Tab character on Debian --- .../auto-type/emitter/auto-type-emitter-linux.js | 11 ++++++++--- release-notes.md | 1 + 2 files changed, 9 insertions(+), 3 deletions(-) diff --git a/app/scripts/auto-type/emitter/auto-type-emitter-linux.js b/app/scripts/auto-type/emitter/auto-type-emitter-linux.js index ca689f43..fc538b16 100644 --- a/app/scripts/auto-type/emitter/auto-type-emitter-linux.js +++ b/app/scripts/auto-type/emitter/auto-type-emitter-linux.js @@ -95,16 +95,21 @@ AutoTypeEmitter.prototype.text = function(text) { }; AutoTypeEmitter.prototype.key = function(key) { - if (typeof key !== 'number') { + const isSpecialKey = typeof key !== 'number'; + if (isSpecialKey) { if (!KeyMap[key]) { return this.callback('Bad key: ' + key); } - key = KeyMap[key].toString(16); + key = KeyMap[key].toString(); } this.pendingScript.push( 'key --clearmodifiers ' + this.windowParameter + this.modString() + key ); - this.callback(); + if (isSpecialKey) { + this.waitComplete(); + } else { + this.callback(); + } }; AutoTypeEmitter.prototype.copyPaste = function(text) { diff --git a/release-notes.md b/release-notes.md index 02f7bf86..db40220b 100644 --- a/release-notes.md +++ b/release-notes.md @@ -15,6 +15,7 @@ Release notes `-` fix #620: clearing middle-click clipboard in Linux `-` fix #1440: fixed auto-type for maximized windows `-` fix #1509: fixed auto-type for tiling mode in Linux +`-` fix #1409: fixed auto-typing Tab character on Debian ##### v1.14.3 (2020-05-15) `*` improved exporting files with markdown notes