Method java.awt.Toolkit.getLockingKeyState(int) is not implemented and throws RuntimeException when called. This prevents some applications like jEdit automated GUI test scenario from running normally, see
HARMONY-3633, it had to provide a special workaround patch to address this issue.
Implementing this method may be tough as it requires writing native code, however a simple workaround patch may be created to improve compatibility while the real implementation is absent. Here I provide this patch (actually extracted from
HARMONY-3633) and my suggestion is to apply it immediately.