Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR SWIFT

xcode hide keyboard when touch background storyboard

override func viewDidLoad()
    {
        super.viewDidLoad()
        
        //Hide Keyboard
        let tap = UITapGestureRecognizer(target: self.view, action: #selector(UIView.endEditing))
        view.addGestureRecognizer(tap)
    }
 
PREVIOUS NEXT
Tagged: #xcode #hide #keyboard #touch #background #storyboard
ADD COMMENT
Topic
Name
2+4 =