WHY THE FUCK DOESN'T THIS WORK?

When the user receives a message and tries to type a response, the caret
jumps up a line. wat do?