| 185 | this.onSelected(code); |
| 186 | } |
| 187 | onCursorBefore(code, sign) { |
| 188 | if (shiftKey) { |
| 189 | if (this.cursorOffset == null) |
| 190 | this.cursorOffset = (sign < 0) ? code.selectionOffset : code.selectionOffset + code.selectionLength; |
| 191 | if (this.cursorAnchor == null) |
| 192 | this.cursorAnchor = (sign < 0) ? code.selectionOffset + code.selectionLength : code.selectionOffset; |
| 193 | return this.cursorOffset; |
| 194 | } |
| 195 | this.cursorOffset = null; |
| 196 | this.cursorAnchor = null; |
| 197 | return (sign < 0) ? code.selectionOffset : code.selectionOffset + code.selectionLength; |
| 198 | } |
| 199 | onCursorCancel(code, sign) { |
| 200 | this.cursorAnchor = null; |
| 201 | this.cursorLocation = null; |