Fixes#6221.
If Keyman is being installed under the SYSTEM profile, e.g. when using
tools such as SCCM or Intune, then the installer runs with a redirected
folder for %LocalAppData%, under C:\Windows\SysWow64\config, but is
given the name C:\Windows\System32\config\....
Keyman Setup then creates %LocalAppData%\Keyman\Diag, which it thinks is
in C:\Windows\System32\config\... But in reality it is in SysWow64\...
Keyman Setup passes a file under this folder to Windows Installer,
running as 64 bit, which immediately falls over because the path does
not exist to it, in the real System32\config folder.
This patch disables redirection temporarily just to create the folder
under both 32 and 64 bit versions of the profile. It has no effect on
normal user accounts (apart from verifying that the folder is present
twice rather than once).
For the TSF applications in most cases there is no test parse
with updatable=false. In these cases we need to call the
core process event function and process the actions in the
one call. A bool flag has been added to track if the core process
event has been called for the current keystroke
The uninstall actions never ran because the working directory given was
invalid. Also fixed: the success/failure message is presented by the
caller rather than down in the depths of the call.
The package version should always be 7.0 for keyboard versions up to and
including 14.0, because Keyman for Window 14 and earlier only accepted
packages with version number 7.0.
Also, we never stream MinKeymanVersion for each keyboard because that
should be calculated at compile time to ensure that we get correct
version which may otherwise be out of date.
In order to avoid the test host interfering too badly with the debugger,
we will bypass SendInput and instead post all input to the local edit
window. This can result in out-of-sequence input for rapid typing, but
for a test host this is not important -- it's better that the input
doesn't end up in the debugger window due to focus changes!
Scratching an itch. It's very painful to debug Keyman Core on Windows.
This helps a little. It allows you to step through the code without
loading keyman32.dll into every process. It's not perfect, because when
actions are sent, they tend to land in the debugger because SendInput
does not care about the active window! However, if you don't care
about that too much (or if you are willing to try a remote debug setup),
then this should really simplify debugging.
Relates to #5992 (part 1 of 2 - part 2 updates the kmn min version in
the compiler).
Updates package fileVersion property to be minimum keyboard version, to
avoid issues with app crashing if functionality is not supported.
As far as I can tell, only Keyman for Windows currently checks the
package fileVersion.
This could be quite nasty, except that the online keyboard repository
build process also extracts the min Keyman version from the keyboard
.kmx and .js, and records it in the .keyboard_info, preventing older
versions of Keyman from seeing unsupported keyboards in the cloud
repository.
Thus, the only gap is for peer distributed keyboards. So we should fix
this gap but it is less urgent than it might otherwise be.
As of Keyman Developer 15, we no longer need to install
keymanengine.msm, so it should be able to co-exist with any version of
Keyman for Windows. Remove the .msm to make this so!
This commit adds call to the core keyboard processor
on wm_keymanim_close event. To get the latest actions.
It also changes the core to allow QIT BACK even when
the context is empty.