Handle middle click to paste selection

This appears to work in Chrome but not Firefox
This commit is contained in:
Daniel Imms
2017-06-20 10:18:29 -07:00
parent 8811d96a8b
commit dc165175cf
4 changed files with 29 additions and 16 deletions
+1 -1
View File
@@ -80,7 +80,7 @@ export function pasteHandler(ev: ClipboardEvent, term: ITerminal) {
* @param term The terminal on which to apply the handled paste event
* @param selectionManager The terminal's selection manager.
*/
export function rightClickHandler(ev: MouseEvent, textarea: HTMLTextAreaElement, selectionManager: ISelectionManager) {
export function moveTextAreaUnderMouseCursor(ev: MouseEvent, textarea: HTMLTextAreaElement, selectionManager: ISelectionManager) {
// Bring textarea at the cursor position
textarea.style.position = 'fixed';
textarea.style.width = '20px';