equal
deleted
inserted
replaced
113 |
113 |
114 [self.listOfWeapons removeObjectAtIndex:row]; |
114 [self.listOfWeapons removeObjectAtIndex:row]; |
115 [self.tableView deleteRowsAtIndexPaths:[NSArray arrayWithObject:indexPath] withRowAnimation:UITableViewRowAnimationFade]; |
115 [self.tableView deleteRowsAtIndexPaths:[NSArray arrayWithObject:indexPath] withRowAnimation:UITableViewRowAnimationFade]; |
116 } |
116 } |
117 |
117 |
118 -(BOOL) tableView:(UITableView *)tableView canEditRowAtIndexPath:(NSIndexPath *)indexPath { |
|
119 UITableViewCell *cell = [self.tableView cellForRowAtIndexPath:indexPath]; |
|
120 if (![cell.textLabel.text isEqualToString:@"Default"]) |
|
121 return YES; |
|
122 else |
|
123 return NO; |
|
124 } |
|
125 |
|
126 #pragma mark - |
118 #pragma mark - |
127 #pragma mark Table view delegate |
119 #pragma mark Table view delegate |
128 -(void) tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath { |
120 -(void) tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath { |
129 if (childController == nil) { |
121 if (childController == nil) { |
130 childController = [[SingleWeaponViewController alloc] initWithStyle:UITableViewStyleGrouped]; |
122 childController = [[SingleWeaponViewController alloc] initWithStyle:UITableViewStyleGrouped]; |