- Also renamed `prefixed` and `withoutPrefix` functions to use the name
that was aliased on most cases: `toPrefixedKeyboardId` and
`toUnprefixedKeyboardId`.
- Renamed `ModelManager` class to `ModelCache` which was the name used
everywhere except in comments.
Part-of: #15292
Test-bot: skip
Fixes#7517.
Cleans up the setDeviceType code which was attempting to set the device
type far too late in the init sequence, and moves responsibility for
detection from kmwembedded.ts to ios-host.ts, as this device test is
iOS-specific.
The iOS code was making a direct call to `keyman.core.resetContext()`
rather than to `keyman.resetContext()`. This meant that the
`OutputTarget` was not set and the `newContext` event would never be
called (as well as triggering a background warning in the language
processor "OutputTarget missing during an invalidateContext call").
Refactored to include a wrapper for `resetContext()` in ios-host.js, as
I think it's better to proxy all calls to KMW consistently through the
host javascript.
(There are a couple of other direct calls which could be cleaned up;
search for "evaluateJavaScript" to find all calls; I think we could
consider build a wrapper for all these calls?)
The refocus of internal edit (setActiveElement) after every keystroke
was causing a `newcontext` event to be triggered. We should never need
to do this, but have chosen to move it within the resetContext pattern,
to minimize the changes.
This is part of the fix chain for #5853. Split ios-host.js out from
keyboard.html in order to make it easier to debug and mock. No changes
to the content of the sscript, just moving it here.
Relates to #949.
Mirror of #5349 (Android), for iOS.
* Adds setSpacebarText() API to Keyman Engine for iOS
* Adds displayName API to Keyman Engine for iOS
* Adds Preference for spacebar text to Keyman Engine for iOS
* Sets default spacebar text to keyboard name for FirstVoices Keyboards