Guest User

Untitled

a guest
Jul 19th, 2018
84
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.82 KB | None | 0 0
  1. - (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath {
  2.  
  3. static NSString *CellIdentifier = @"Cell";
  4.  
  5. UITableViewCell *cell = [tableView dequeueReusableCellWithIdentifier:CellIdentifier];
  6. if (cell == nil) {
  7. cell = [[[UITableViewCell alloc] initWithFrame:CGRectZero reuseIdentifier:CellIdentifier] autorelease];
  8. }
  9.  
  10. // Set up the cell...
  11. NSString *cellValue = [itemsList objectAtIndex:indexPath.row];
  12. cell.textLabel.text = cellValue;
  13.  
  14. return cell;
  15. }
  16.  
  17. cell = [[[UITableViewCell alloc] initWithFrame:CGRectZero reuseIdentifier:CellIdentifier] autorelease];
  18.  
  19. - initWithStyle:reuseIdentifier:
  20.  
  21. if (cell == nil) {
  22.  
  23. cell = [[[UITableViewCell alloc] initWithStyle:UITableViewCellStyleDefault reuseIdentifier:CellIdentifier] autorelease];
  24.  
  25. }
Add Comment
Please, Sign In to add comment