detect key repeat in raw input