add visual bell when no replacements are available

also add try/catch in _tabCompleteName so errors don't get swallowed
This commit is contained in:
Bruno Windels 2019-08-28 15:53:16 +02:00
parent c44fbb73d0
commit 85efb71a23
3 changed files with 53 additions and 18 deletions

View file

@ -33,6 +33,10 @@ export default class AutocompleteWrapperModel {
});
}
close() {
this._updateCallback({close: true});
}
hasSelection() {
return this._getAutocompleterComponent().hasSelection();
}
@ -67,7 +71,7 @@ export default class AutocompleteWrapperModel {
// so we can restore it in onComponentSelectionChange when the value is undefined (meaning it should be the typed text)
this._queryPart = part;
this._queryOffset = offset;
this._updateQuery(part.text);
return this._updateQuery(part.text);
}
onComponentSelectionChange(completion) {