Setting the delegate for UITextField