]> git.proxmox.com Git - mirror_xterm.js.git/commitdiff
Merge branch 'master' into guard_selection_api
authorDaniel Imms <tyriar@tyriar.com>
Fri, 14 Jul 2017 16:51:58 +0000 (09:51 -0700)
committerGitHub <noreply@github.com>
Fri, 14 Jul 2017 16:51:58 +0000 (09:51 -0700)
src/SelectionManager.ts
src/xterm.js

index ac7fd0177835b440044f5b4c25c2a7d22edbdb79..31ee8c2c8f677e6b34ee8ba2bade1680b43abd3b 100644 (file)
@@ -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.
index f82d46b5eddae3070775aea6c134b701e2bfa524..a97070961df2e722c77a229a5ce5e20fb5d3a6e8 100644 (file)
@@ -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();