Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Change disclosure indicator color on cell selection

I've read some posts on this, but still can't get the answer to my question.

I have a disclosure indicator. enter image description here

I add it like this:

cell.accessoryType = UITableViewCellAccessoryDisclosureIndicator;

Everything works fine and is good, the only thing i want to change is when i press down the cell, disclosure indicator changes color to white. enter image description here I don't want that. So my question is how to make the disclosure indicator color fixed, and not changing?

like image 388
Lukas Avatar asked Jul 10 '12 06:07

Lukas


1 Answers

I was facing the same problem and found even you're struggling with this...though its quite late answer but I sorted out my issue by writing the following line,

cell.selectionStyle = UITableViewCellSelectionStyleNone;

it stopped accessory type UITableViewCellAccessoryDisclosureIndicator from being white when selected.

Hope this helped.


Swift version:

cell.selectionStyle = .none

like image 90
MPG Avatar answered Sep 25 '22 08:09

MPG