mirror of
https://github.com/keymanapp/keyman.git
synced 2026-08-10 02:45:32 +00:00
change(web): better fix - no parameterless selectBanner calls
This commit is contained in:
parent
4a64c193ed
commit
ea266eef22
1 changed files with 4 additions and 4 deletions
|
|
@ -143,6 +143,8 @@ namespace com.keyman.osk {
|
|||
this.alwaysShow = optionSpec[key];
|
||||
break;
|
||||
case 'mayPredict':
|
||||
// If this toggles our internal flag, it will generate events
|
||||
// that reconfigures the banner (and internal engine state) appropriately.
|
||||
keyman.core.languageProcessor.mayPredict = optionSpec[key]
|
||||
break;
|
||||
case 'mayCorrect':
|
||||
|
|
@ -157,8 +159,6 @@ namespace com.keyman.osk {
|
|||
}
|
||||
this._options[key] = optionSpec[key];
|
||||
}
|
||||
|
||||
this.selectBanner();
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
@ -208,11 +208,11 @@ namespace com.keyman.osk {
|
|||
* allowing logic to automatically hot-swap `Banner`s as needed.
|
||||
* @param state
|
||||
*/
|
||||
private selectBanner(state?: text.prediction.StateChangeEnum) {
|
||||
private selectBanner(state: text.prediction.StateChangeEnum) {
|
||||
// Only display a SuggestionBanner when LanguageProcessor states it is active.s
|
||||
if(state == 'active') {
|
||||
this.setBanner('suggestion');
|
||||
} else if(state == 'inactive' || state == undefined) {
|
||||
} else if(state == 'inactive') {
|
||||
if(this.alwaysShow) {
|
||||
this.setBanner('image');
|
||||
} else {
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue