Fixed a problem with text selection