Skip to content

Commit a75aced

Browse files
committed
amendment
1 parent 689bec9 commit a75aced

File tree

3 files changed

+4
-4
lines changed

3 files changed

+4
-4
lines changed

Example/app/widget/AutoDragSortableView.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -559,7 +559,6 @@ export default class AutoDragSortableView extends Component{
559559
}
560560

561561
scrollTo = (height, animated = true) => {
562-
this.isHasMeasure = true
563562
// Prevent iOS from sliding when elastically sliding negative numbers
564563
if (this.curScrollData) {
565564
if (this.autoObj.forceScrollStatus < 0 && this.curScrollData.offsetY <= 0) {
@@ -583,7 +582,8 @@ export default class AutoDragSortableView extends Component{
583582
offsetY: nativeEvent.contentOffset.y,
584583
hasScroll: true,
585584
}
586-
if (this.props.onScrollListener) this.props.onScrollListener(event)
585+
if (nativeEvent.contentOffset.y !== 0) this.isHasMeasure = true
586+
if (this.props.onScrollListener) this.props.onScrollListener(event);
587587
}
588588

589589
render() {

lib/AutoDragSortableView.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -559,7 +559,6 @@ export default class AutoDragSortableView extends Component{
559559
}
560560

561561
scrollTo = (height, animated = true) => {
562-
this.isHasMeasure = true
563562
// Prevent iOS from sliding when elastically sliding negative numbers
564563
if (this.curScrollData) {
565564
if (this.autoObj.forceScrollStatus < 0 && this.curScrollData.offsetY <= 0) {
@@ -583,6 +582,7 @@ export default class AutoDragSortableView extends Component{
583582
offsetY: nativeEvent.contentOffset.y,
584583
hasScroll: true,
585584
}
585+
if (nativeEvent.contentOffset.y !== 0) this.isHasMeasure = true;
586586
if (this.props.onScrollListener) this.props.onScrollListener(event)
587587
}
588588

lib/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "react-native-drag-sort",
3-
"version": "2.4.1",
3+
"version": "2.4.2",
44
"description": "Drag and drop sort control for react-native",
55
"main": "index.js",
66
"scripts": {

0 commit comments

Comments
 (0)