8131017: jshell tool: pasting code with tabs invokes tab completion

Enabling copy-paste detection.

Reviewed-by: lagergren, sundar
This commit is contained in:
Jan Lahoda 2016-05-24 16:03:48 +02:00
parent 2baa671d45
commit 390c90f8de

View File

@ -58,6 +58,7 @@ class Console implements AutoCloseable {
in.setExpandEvents(false);
in.setHandleUserInterrupt(true);
in.setBellEnabled(true);
in.setCopyPasteDetection(true);
in.setHistory(new EditingHistory(in, Files.readAllLines(historyFile.toPath())) {
@Override protected boolean isComplete(CharSequence input) {
return completer.isComplete(input.toString());