Simplify input key handling.