Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Tinted buttons in cells changing colors #12

Open
valeriologiudice opened this issue Nov 2, 2017 · 1 comment
Open

Tinted buttons in cells changing colors #12

valeriologiudice opened this issue Nov 2, 2017 · 1 comment

Comments

@valeriologiudice
Copy link

Hello, great library! I have an issue for buttons with images that I tint to change their color inside a cell. When I start the dragging the cell the tint color that I set is re-setted to the buttons image original colors. For example I've set the tint color for those buttons to be green and when dragging starts the buttons became black, witch is the image original color. Thanks again for this very useful library, best.

@thejeff77
Copy link

@valeriologiudice I don't think this is an issue with this library. I forgot where I found the solution, but this is just an ios thing - the tints/backgrounds sometimes get reset when a cell is set to selected or highlighted. In order to fix this, I recommend overriding a couple methods in your UITableViewCell:

- (void)setHighlighted:(BOOL)highlighted animated:(BOOL)animated
{
    [super setHighlighted:highlighted animated:animated];
    // re-set any tint/background that is changed to what it should be
}

- (void)setSelected:(BOOL)selected animated:(BOOL)animated
{
    [super setSelected:selected animated:animated];
    // re-set any tint/background that is changed to what it should be
}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants