Skip to content

Commit

Permalink
fix(*): fix code.
Browse files Browse the repository at this point in the history
  • Loading branch information
shangqunfeng committed Dec 19, 2024
1 parent 0cbeca5 commit 016b974
Showing 1 changed file with 3 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -613,7 +613,6 @@ export function pickStyle (styleObj: Record<string, any> = {}, pickedKeys: Array
}, {})
}


export function useGesture ({ onTouchStart, onTouchEnd }: { onTouchStart: () => void, onTouchEnd: () => void }) {
const gestureRef: React.RefObject<any> = useContext(ScrollViewContext).gestureRef

Expand All @@ -628,9 +627,9 @@ export function useGesture ({ onTouchStart, onTouchEnd }: { onTouchStart: () =>
runOnJS(onTouchEnd)()
})

if (gestureRef) {
gesturePan.simultaneousWithExternalGesture(gestureRef)
}
if (gestureRef) {
gesturePan.simultaneousWithExternalGesture(gestureRef)
}

return gesturePan
}

0 comments on commit 016b974

Please sign in to comment.