Skip to content

Commit 57133e0

Browse files
committed
performBatchUpdates not needed when changing single indexPath
1 parent d3d273e commit 57133e0

File tree

3 files changed

+3
-9
lines changed

3 files changed

+3
-9
lines changed

XBMC Remote/HostManagementViewController.m

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -248,9 +248,7 @@ - (void)tableView:(UITableView*)tableView commitEditingStyle:(UITableViewCellEdi
248248
[AppDelegate.instance saveServerList];
249249
}
250250
if (indexPath.row < [tableView numberOfRowsInSection:indexPath.section]) {
251-
[tableView performBatchUpdates:^{
252-
[tableView deleteRowsAtIndexPaths:@[indexPath] withRowAnimation:UITableViewRowAnimationRight];
253-
} completion:nil];
251+
[tableView deleteRowsAtIndexPaths:@[indexPath] withRowAnimation:UITableViewRowAnimationRight];
254252
}
255253

256254
// Be aware! Sending "XBMCServerHasChanged" results in calling reloadData. Therefore ensure this is not called

XBMC Remote/NowPlaying.m

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2233,9 +2233,7 @@ - (void)tableView:(UITableView*)tableView commitEditingStyle:(UITableViewCellEdi
22332233
[playlistData removeObjectAtIndex:indexPath.row];
22342234
}
22352235
if (indexPath.row < [playlistTableView numberOfRowsInSection:indexPath.section]) {
2236-
[playlistTableView performBatchUpdates:^{
2237-
[playlistTableView deleteRowsAtIndexPaths:@[indexPath] withRowAnimation:UITableViewRowAnimationRight];
2238-
} completion:nil];
2236+
[playlistTableView deleteRowsAtIndexPaths:@[indexPath] withRowAnimation:UITableViewRowAnimationRight];
22392237
}
22402238
if (storeSelection && indexPath.row < storeSelection.row) {
22412239
storeSelection = [NSIndexPath indexPathForRow:storeSelection.row - 1 inSection:storeSelection.section];

XBMC Remote/RightMenuViewController.m

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -303,9 +303,7 @@ - (void)tableView:(UITableView*)tableView commitEditingStyle:(UITableViewCellEdi
303303
[tableData removeObjectAtIndex:indexPath.row];
304304
}
305305
if (indexPath.row < [tableView numberOfRowsInSection:indexPath.section]) {
306-
[tableView performBatchUpdates:^{
307-
[tableView deleteRowsAtIndexPaths:@[indexPath] withRowAnimation:UITableViewRowAnimationRight];
308-
} completion:nil];
306+
[tableView deleteRowsAtIndexPaths:@[indexPath] withRowAnimation:UITableViewRowAnimationRight];
309307
}
310308
[self deleteCustomButton:indexPath.row];
311309
}

0 commit comments

Comments
 (0)