]> git.proxmox.com Git - mirror_xterm.js.git/commitdiff
Merge branch 'master' into 553_find_api
authorDaniel Imms <tyriar@tyriar.com>
Wed, 21 Jun 2017 00:44:43 +0000 (17:44 -0700)
committerGitHub <noreply@github.com>
Wed, 21 Jun 2017 00:44:43 +0000 (17:44 -0700)
1  2 
src/SelectionManager.ts

index f027e4a3f77dec9fcc11dfcf69e8c5103e6d3fcf,a769afd113c79a504fdfdab13005d4d95c939579..0151427c0caf18fd31e39b4fac31a1c293c09390
@@@ -521,22 -592,13 +547,21 @@@ export class SelectionManager extends E
      return charIndex;
    }
  
 +  public setSelection(col: number, row: number, length: number): void {
 +    this._model.clearSelection();
 +    this._removeMouseDownListeners();
 +    this._model.selectionStart = [col, row];
 +    this._model.selectionStartLength = length;
 +    this.refresh();
 +  }
 +
    /**
-    * Selects the word at the coordinates specified. Words are defined as all
-    * non-whitespace characters.
+    * Gets positional information for the word at the coordinated specified.
     * @param coords The coordinates to get the word at.
     */
-   protected _selectWordAt(coords: [number, number]): void {
+   private _getWordAt(coords: [number, number]): IWordPosition {
      const bufferLine = this._buffer.get(coords[1]);
 -    const line = this._translateBufferLineToString(bufferLine, false);
 +    const line = translateBufferLineToString(bufferLine, false);
  
      // Get actual index, taking into consideration wide characters
      let endIndex = this._convertViewportColToCharacterIndex(bufferLine, coords);