messages are only selected when clicking on the text, improved focus handling