Search resetting selection in tableview
- by Jay
I've got an NSTableView bound to an NSArrayController via content and selection indexes. All great so far - content displayed, etc.
Now an NSSearchField is bound to the array controller via filterPredicate and the property of the array content instances that's to be searched.
Searching/filtering the table view works great; table view showing only matching entries.
However, searching resets the selection on the NSTableView if the existing selection isn't in the search results. Worse, not only during the search but after ending the search there's no selection on the table view.
The NSArrayController is set up to Avoid Empty Selection.
Any hints on how to properly configure bindings in this scenario to really prevent an empty selection much appreciated!