diff --git a/src/SelectionManager.ts b/src/SelectionManager.ts index ac7fd01778..31ee8c2c8f 100644 --- a/src/SelectionManager.ts +++ b/src/SelectionManager.ts @@ -27,18 +27,6 @@ const DRAG_SCROLL_MAX_SPEED = 15; */ const DRAG_SCROLL_INTERVAL = 50; -/** - * The amount of time before mousedown events are no longer stacked to create - * double/triple click events. - */ -const CLEAR_MOUSE_DOWN_TIME = 400; - -/** - * The number of pixels in each direction that the mouse must move before - * mousedown events are no longer stacked to create double/triple click events. - */ -const CLEAR_MOUSE_DISTANCE = 10; - /** * A string containing all characters that are considered word separated by the * double click to select work logic. diff --git a/src/xterm.js b/src/xterm.js index f82d46b5ed..a97070961d 100644 --- a/src/xterm.js +++ b/src/xterm.js @@ -2238,6 +2238,11 @@ Terminal.prototype.handler = function(data) { return; } + // Clear the selection if the selection manager is available and has an active selection + if (this.selectionManager && this.selectionManager.hasSelection) { + this.selectionManager.clearSelection(); + } + // Input is being sent to the terminal, the terminal should focus the prompt. if (this.ybase !== this.ydisp) { this.scrollToBottom();