Filter which runs before process_key_event.
This is particularly useful for NICOLA.
NicolaKeyEventFilter