Commit 6ae7dfa8 by Javier Heisekce

Borra reimplementacion de funciones de searchbar

parent 5c1677a9
...@@ -21,6 +21,7 @@ class ContactsViewController: UIViewController { ...@@ -21,6 +21,7 @@ class ContactsViewController: UIViewController {
super.viewDidLoad() super.viewDidLoad()
contactsTable.register(UINib(nibName: "ContactSection", bundle: nil), forHeaderFooterViewReuseIdentifier: "headerId") contactsTable.register(UINib(nibName: "ContactSection", bundle: nil), forHeaderFooterViewReuseIdentifier: "headerId")
importContacts() importContacts()
searchBar.delegate = self
contactsTable.tableFooterView = UIView(frame: .zero) contactsTable.tableFooterView = UIView(frame: .zero)
searchBar.placeholder = NSLocalizedString("Nombre...", comment: "") searchBar.placeholder = NSLocalizedString("Nombre...", comment: "")
} }
...@@ -151,15 +152,6 @@ extension ContactsViewController: UISearchBarDelegate, UISearchDisplayDelegate, ...@@ -151,15 +152,6 @@ extension ContactsViewController: UISearchBarDelegate, UISearchDisplayDelegate,
} }
func searchBarTextDidEndEditing(_ searchBar: UISearchBar) {
self.searchBar.showsCancelButton = false
}
func searchBarTextDidBeginEditing(_ searchBar: UISearchBar) {
self.searchBar.showsCancelButton = true
self.searchBar.resignFirstResponder()
}
func searchBar(_ searchBar: UISearchBar, textDidChange searchText: String) { func searchBar(_ searchBar: UISearchBar, textDidChange searchText: String) {
print(searchText) print(searchText)
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment