新しい UISearchController を使用する iOS 8 アプリを構築しています。検索コントローラーに関連するテーブル ビューでは、セクション インデックスを使用して、ユーザーがテーブルのあるセクションから次のセクションにすばやくジャンプできるようにしています。正常に動作していますが、セクション インデックスがテーブル/検索コントローラーの検索バーと重なっています。以前にこの問題に遭遇した人はいますか? もしそうなら、どのように解決しましたか? 以下は、検索コントローラーを初期化する方法です。
self.resultsTableController = [self.storyboard instantiateViewControllerWithIdentifier:[SelectSpecialtySearchResultsTVC storyboardId]];
UINavigationController *searchResultsNavController = [[UINavigationController alloc]initWithRootViewController:self.resultsTableController];
self.searchController = [[UISearchController alloc] initWithSearchResultsController:searchResultsNavController];
self.searchController.searchResultsUpdater = self;
self.searchController.hidesNavigationBarDuringPresentation = NO;
self.searchController.searchBar.barTintColor = [UIColor colorWithHexString:kColorGrayLight];
self.searchController.searchBar.translucent = NO;
self.searchController.searchBar.frame = CGRectMake(self.searchController.searchBar.frame.origin.x, self.searchController.searchBar.frame.origin.y, [self.view bounds].size.width, 44.0);
self.searchController.searchBar.delegate = self;
self.tableView.tableHeaderView = self.searchController.searchBar;
//present the search display controller within the confines of this class's table view
self.definesPresentationContext = YES;
// we want to be the delegate for our filtered table so didSelectRowAtIndexPath is called for both tables
self.resultsTableController.tableView.delegate = self;
self.searchController.delegate = self;