clenup
This commit is contained in:
parent
26f96c0ea2
commit
79f619364a
2 changed files with 4 additions and 8 deletions
|
|
@ -181,11 +181,9 @@ var Autocomplete = function() {
|
||||||
"Esc": function(editor) { editor.completer.detach(); },
|
"Esc": function(editor) { editor.completer.detach(); },
|
||||||
"Space": function(editor) { editor.completer.detach(); editor.insert(" ");},
|
"Space": function(editor) { editor.completer.detach(); editor.insert(" ");},
|
||||||
"Return": function(editor) {
|
"Return": function(editor) {
|
||||||
if (editor.completer.popup.getRow() > -1) {
|
if (editor.completer.popup.getRow() == -1)
|
||||||
|
return false;
|
||||||
editor.completer.insertMatch();
|
editor.completer.insertMatch();
|
||||||
} else {
|
|
||||||
editor.insert("\n");
|
|
||||||
}
|
|
||||||
},
|
},
|
||||||
"Shift-Return": function(editor) { editor.completer.insertMatch(true); },
|
"Shift-Return": function(editor) { editor.completer.insertMatch(true); },
|
||||||
"Tab": function(editor) { editor.completer.insertMatch(); },
|
"Tab": function(editor) { editor.completer.insertMatch(); },
|
||||||
|
|
@ -290,8 +288,7 @@ var Autocomplete = function() {
|
||||||
return doDetach();
|
return doDetach();
|
||||||
|
|
||||||
// Wrong prefix or wrong session -> ignore
|
// Wrong prefix or wrong session -> ignore
|
||||||
if (prefix.indexOf(results.prefix) != 0
|
if (prefix.indexOf(results.prefix) != 0 || _id != this.gatherCompletionsId)
|
||||||
|| _id != this.gatherCompletionsId)
|
|
||||||
return;
|
return;
|
||||||
|
|
||||||
this.completions = new FilteredList(matches);
|
this.completions = new FilteredList(matches);
|
||||||
|
|
|
||||||
|
|
@ -114,7 +114,6 @@ var Tokenizer = function(rules) {
|
||||||
// makes property access faster
|
// makes property access faster
|
||||||
if (!rule.onMatch)
|
if (!rule.onMatch)
|
||||||
rule.onMatch = null;
|
rule.onMatch = null;
|
||||||
rule.__proto__ = null;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
splitterRurles.forEach(function(rule) {
|
splitterRurles.forEach(function(rule) {
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue