Skip to content

Commit e6ddebc

Browse files
committed
Set the correct background color when inside a highlighted cell.
1 parent 88a2b25 commit e6ddebc

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

Classes/ios/FUISwitch.m

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -182,6 +182,13 @@ - (void) updateBackground {
182182
self.thumbView.backgroundColor = contentColor;
183183
}
184184

185+
- (void)setHighlighted:(BOOL)highlighted {
186+
[super setHighlighted:highlighted];
187+
188+
if (highlighted)
189+
self.backgroundColor = self.highlightedColor;
190+
}
191+
185192
- (void) touchesBegan:(NSSet *)touches withEvent:(UIEvent *)event {
186193
[super touchesBegan:touches withEvent:event];
187194
[self setHighlighted:YES];

0 commit comments

Comments
 (0)