This question is locked. New answers and comments are not allowed.
Hi,
I want to add a different background color to the item in the side drawer which is currently selected. For that purpose, I added the following delegate implementation:
- (TKSideDrawerTableViewCell *)sideDrawer:(TKSideDrawer *)sideDrawer cellForItemAtIndexPath:(NSIndexPath *)indexPath {
TKSideDrawerSection *section = sideDrawer.sections[indexPath.section];
TKSideDrawerItem *item = section.items[indexPath.item];
TKSideDrawerTableViewCell *cell = [[TKSideDrawerTableViewCell alloc] init];
cell.item = item;
cell.selectedBackgroundView = [[UIView alloc] init];
cell.selectedBackgroundView.backgroundColor = [UIColor colorWith...];
cell.selectionStyle = UITableViewCellSelectionStyleGray;
return
cell;
}
which works almost fine.
The problem is that in this case, the separator styling is no longer applied to the cells (e.g. item.style.separatorColor is ignored). How do I have to setup the TKSideDrawerTableviewCell so that it still respects the separator styling?
A second, related question: Is there any non-hacky way to set the initially selected item (read: send a [tableView selectRowAtIndexPath...] to the TKSideDrawerTableView)?