uisearchcontroller在TVOS中制作动画

时间:2019-04-04 07:59:32

标签: tvos uisearchcontroller

我在TVOS中有一个搜索控制器,最底层的目的是在表视图中显示搜索结果。滚动搜索结果时,搜索键盘被隐藏了

我尝试在搜索容器下导入搜索控制器。我的搜索控制器不在选项卡视图控制器下,而是在看起来像标签栏的容器内。在TVOS中遇到上述问题

let searchController = UISearchController(searchResultsController: searchResultsController)
searchController.searchResultsUpdater = searchResultsController
searchController.searchBar.placeholder = NSLocalizedString("Enter keyword (e.g. iceland)", comment: "")
searchController.definesPresentationContext = true
searchController.hidesNavigationBarDuringPresentation = false
// Contain the `UISearchController` in a `UISearchContainerViewController`.
let searchContainer = UISearchContainerViewController(searchController: searchController)
searchContainer.title = NSLocalizedString("Search", comment: "")

我看起来很相似,但不是在容器中显示的tabor iam中显示

如果表视图列表很大,则搜索控制器将被最小化/隐藏

请帮助我解决这个问题

谢谢

0 个答案:

没有答案