Search code examples
iosuitableviewuisearchdisplaycontroller

Double grid lines on drag?


I have a table with a search bar. I find that when the search interface is dismissed, sometimes double grid lines appear in the bottom half of the grid. One set moves with the finger as you move the table, the other set remains pinned to the screen.

This looks like this:

Screenshot

Reproducing this takes a lot of effort, so I've uploaded a small test project to github.

I've also prepared a QuickTime movie of the bug in action:

The key points seem to be:

  • Table sections are in use.
  • A search that returns a small subset of rows.

Things I've tried:

  • Setting the search result table's rowHeight.
  • Setting the backgroundColor of both tables and all cells to [UIColor whiteColor].
  • Tried reloadData on the search results table view instead of self.tableView in updateSearchResults. (This is probably what I should be doing, but it didn't help with this problem.)

Does anyone have any insight as to what's happening here? And, of course, how to fix it.


Solution

  • I ended up using a Developer Technical Support incident for this.

    And so, for posterity: This is caused by working at the wrong level; instead of working with the UISearchBar messages, work with the UISearchBarController messages.