iOS: Search bar disappears in view controller with table view

Viewed 33

I have a problem when I set a UISearchBar in the navigation item of a view controller with a table view. When I am using the swipe gesture to navigate back from a view controller with this setup, but then cancel the gesture, such that the view reappears, the search bar will disappear.

enter image description here

For this example I created a new project where I set the navigation in a storyboard and only assign the search controller in viewDidLoad of the pushed view controller.

Does anyone have an idea why this is happening?

0 Answers
Related