Skip to content
Snippets Groups Projects
Commit eac55859 authored by Marijn Haverbeke's avatar Marijn Haverbeke
Browse files

[show-hint addon] Fix bugs introduced by supportsSelection changes

Issue #3525
parent b0d525ac
No related branches found
No related tags found
No related merge requests found
......@@ -25,7 +25,7 @@
};
CodeMirror.defineExtension("showHint", function(options) {
options = parseOptions(this, options);
options = parseOptions(this, this.getCursor("start"), options);
var selections = this.listSelections()
if (selections.length > 1) return;
// By default, don't allow completion when something is selected.
......@@ -395,6 +395,8 @@
return function(cm) { return CodeMirror.hint.fromList(cm, {words: words}) }
} else if (CodeMirror.hint.anyword) {
return function(cm, options) { return CodeMirror.hint.anyword(cm, options) }
} else {
return function() {}
}
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment