Added keypress detection and default item select state