Created
July 3, 2015 07:36
-
-
Save tuchangwei/e01fc62bd48d0cbbf35f to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-(void)viewDidLayoutSubviews | |
{ | |
if ([self.tableView respondsToSelector:@selector(setSeparatorInset:)]) { | |
[self.tableView setSeparatorInset:UIEdgeInsetsMake(0,0,0,0)]; | |
} | |
if ([self.tableView respondsToSelector:@selector(setLayoutMargins:)]) { | |
[self.tableView setLayoutMargins:UIEdgeInsetsMake(0,0,0,0)]; | |
} | |
} | |
-(void)tableView:(UITableView *)tableView willDisplayCell:(UITableViewCell *)cell forRowAtIndexPath:(NSIndexPath *)indexPath | |
{ | |
if ([cell respondsToSelector:@selector(setSeparatorInset:)]) { | |
[cell setSeparatorInset:UIEdgeInsetsZero]; | |
} | |
if ([cell respondsToSelector:@selector(setLayoutMargins:)]) { | |
[cell setLayoutMargins:UIEdgeInsetsZero]; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment