diff --git a/src/xterm.js b/src/xterm.js index d625a3cf..16c88a91 100644 --- a/src/xterm.js +++ b/src/xterm.js @@ -2234,6 +2234,11 @@ Terminal.prototype.handler = function(data) { return; } + // Clear the selection + if (this.hasSelection()) { + this.clearSelection(); + } + // Input is being sent to the terminal, the terminal should focus the prompt. if (this.ybase !== this.ydisp) { this.scrollToBottom();