Skip to content

Commit

Permalink
Fix pasting in Windows to Linux remote (microsoft#78998)
Browse files Browse the repository at this point in the history
This reverts back to the previous behavior

Fixes microsoft#78981
  • Loading branch information
Tyriar authored and alexr00 committed Aug 13, 2019
1 parent fe5bbea commit a999d54
Showing 1 changed file with 5 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -871,7 +871,11 @@ export class TerminalInstance implements ITerminalInstance {

public async paste(): Promise<void> {
this.focus();
this._xterm._core._coreService.triggerDataEvent(await this._clipboardService.readText(), true);
if (platform.isWeb) {
this._xterm._core._coreService.triggerDataEvent(await this._clipboardService.readText(), true);
} else {
document.execCommand('paste');
}
}

public write(text: string): void {
Expand Down

0 comments on commit a999d54

Please sign in to comment.