Added backspace and enter key support