Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Disable colour change when source list loses focus

When an item is selected in the source list it is highlighted in blue. When another element on the window is selected, however, the highlight becomes a lighter blue as the source list is no longer focused.

I would like to change the behaviour so the item is always the darker blue, the same behaviour as seen in Finder.

like image 866
ICR Avatar asked Apr 06 '10 00:04

ICR


1 Answers

It seems that the source list of Finder never become the fist responder, so, I guess that the first step is to subclass your table view or outline view, and implement the - (BOOL)acceptsFirstResponder method

- (BOOL)acceptsFirstResponder
{
    return NO;
}

It will make the selection of your source list always stay light blue, and you may use some undocumented methods such as _highlightColorForCell to change the highlight color.

like image 70
zonble Avatar answered Sep 21 '22 12:09

zonble