mirror of
https://github.com/Instagram/IGListKit
synced 2026-05-23 17:28:22 +00:00
Add diffResult as argument to pass to willCrashWithException: in IGListAdapterUpdaterDelegate
Summary: This would help us understands what was the diff result from the algorithm and compare it with the `updates` to check what went wrong. Essentially, this would make our debugging easier going forward. Reviewed By: calimarkus Differential Revision: D12828892 fbshipit-source-id: 6dc52cdba1adb5a841760b51599e2df4c845c364
This commit is contained in:
parent
c1bf5f1261
commit
039e77e359
3 changed files with 5 additions and 0 deletions
|
|
@ -10,6 +10,8 @@ The changelog for `IGListKit`. Also see the [releases](https://github.com/instag
|
|||
|
||||
- Renamed `[IGListAdapterUpdatingDelegate listAdapterUpdater:willPerformBatchUpdatesWithCollectionView:]` to `[IGListAdapterUpdatingDelegate listAdapterUpdater:willPerformBatchUpdatesWithCollectionView:fromObjects:toObjects:listIndexSetResult:]` to include more supporting info on updated objects. [Jeremy Cohen] (https://github.com/jeremycohen) (tbd)
|
||||
|
||||
- Renamed `[IGListAdapterUpdatingDelegatelistAdapterUpdater:collectionView:willCrashWithException:fromObjects:toObjects:updates:]` to `[ IGListAdapterUpdatingDelegatelistAdapterUpdater:collectionView:willCrashWithException:fromObjects:toObjects:diffResult:updates:]` to include diff result info. [Zhisheng Huang] (https://github.com/lorixx) (tbd)
|
||||
|
||||
### Enhancements
|
||||
|
||||
- Added `IGListCollectionScrollingTraits` for exposing `UICollectionView` scrolling traits to section controllers via `IGListCollectionContext`. [Adam Stern](https://github.com/adamastern) (tbd)
|
||||
|
|
|
|||
|
|
@ -255,6 +255,7 @@ willPerformBatchUpdatesWithCollectionView:collectionView
|
|||
willCrashWithException:exception
|
||||
fromObjects:fromObjects
|
||||
toObjects:toObjects
|
||||
diffResult:result
|
||||
updates:(id)self.applyingUpdateData];
|
||||
@throw exception;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -141,6 +141,7 @@ willPerformBatchUpdatesWithCollectionView:(UICollectionView *)collectionView
|
|||
@param exception The exception thrown by the collection view.
|
||||
@param fromObjects The items transitioned from in the diff, if any.
|
||||
@param toObjects The items transitioned to in the diff, if any.
|
||||
@param diffResult The diff result that were computed from `fromObjects` and `toObjects`.
|
||||
@param updates The batch updates that were applied to the collection view.
|
||||
*/
|
||||
- (void)listAdapterUpdater:(IGListAdapterUpdater *)listAdapterUpdater
|
||||
|
|
@ -148,6 +149,7 @@ willPerformBatchUpdatesWithCollectionView:(UICollectionView *)collectionView
|
|||
willCrashWithException:(NSException *)exception
|
||||
fromObjects:(nullable NSArray *)fromObjects
|
||||
toObjects:(nullable NSArray *)toObjects
|
||||
diffResult:(IGListIndexSetResult *)diffResult
|
||||
updates:(IGListBatchUpdateData *)updates;
|
||||
|
||||
@end
|
||||
|
|
|
|||
Loading…
Reference in a new issue