mirror of
https://github.com/zhigang1992/react-native.git
synced 2026-01-12 22:50:10 +08:00
make sure onLayout calls _updateViewableItems immediately
Summary: Makes sure `onViewableItemsChanged` fires ASAP when `waitForInterations` is false. This also works around another deeper bug where updates scheduled with `InteractionManager` aren't firing at all in some cases, and thus instead of just firing late, `onViewableItemsChanged` isn't firing until scroll which is not what we want with `waitForInterations: false`. That bug will require more digging. Differential Revision: D14984333 fbshipit-source-id: 718b39670307c6bc16268759bdb513682745265d
This commit is contained in:
committed by
Facebook Github Bot
parent
30a0ce27b1
commit
efe6a0f0b5
@@ -1097,6 +1097,7 @@ class VirtualizedList extends React.PureComponent<Props, State> {
|
||||
}
|
||||
|
||||
this._computeBlankness();
|
||||
this._updateViewableItems(this.props.data);
|
||||
}
|
||||
|
||||
_onCellUnmount = (cellKey: string) => {
|
||||
|
||||
Reference in New Issue
Block a user