Skip to content

Commit d20a461

Browse files
committed
Merge pull request #569 from benoit-pierre/fix_shift_insert_paste
fix command line Shift+Insert paste on Linux
2 parents f1d5ee0 + f9cd1ef commit d20a461

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

common/content/editor.js

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -70,6 +70,10 @@ const Editor = Module("editor", {
7070
return;
7171
}
7272

73+
// clear completion preview so it does not get turned into regular text
74+
if (commandline._completions)
75+
commandline._completions.previewClear();
76+
7377
let elem = liberator.focus;
7478

7579
if (elem.setSelectionRange && util.readFromClipboard()) {
@@ -91,6 +95,10 @@ const Editor = Module("editor", {
9195
elem.scrollTop = curTop;
9296
elem.scrollLeft = curLeft;
9397
}
98+
99+
// update completion preview as would happen with Ctrl+v or mouse paste
100+
if (commandline._completions && options.autocomplete)
101+
commandline._completions.complete(true, false);
94102
},
95103

96104
// count is optional, defaults to 1

0 commit comments

Comments
 (0)