Fix unintended double write of pressed keys