Added code to deselect text when double clicking