| fix: fix GenerateKeyOptionKey format mismatch breaking old API on('key') callbacks BUG-4 (Fatal): GenerateKeyOptionKey produced keys in GetEventInfoAPI26 format (preKeys,finalKey,finalKeyDownDuration,...) for old API path, but GetEventInfoAPI9 stores keys as (preKeys,finalKey,isFinalKeyDown, finalKeyDownDuration,isRepeat). The swapped field positions caused 100% callback lookup failure for all apps using the old on('key') API. BUG-5: UnsubscribeKeyCommand used GenerateKeyOptionKey to clear TriggerEventDispatcher state, but the internal GenerateSubscribeKey uses a completely different format. Added ClearSubscribeState(KeyOption) overload to generate the correct key internally. Both NAPI and ETS layers are affected and fixed. Signed-off-by: JustinHu <gchenghu@126.com> Co-Authored-By: Agent | 3 个月前 |