The ScrollView in Scrollview can not scroll on android

See original GitHub issue

Issue Description

The code struct is like below

  <ScrollView>
       <ScrollView>
          something...
       </ScrollView>
       ...
 </ScrollView>

The Inner scrollview would never catch any events and repsond to scroll inner, the outer scrollveiw catch all the scroll events

I seached from some issues but not work https://github.com/facebook/react-native/issues/41

Also I set panRepsoner of innter srollview , not work.

Something else , It’s ok on ios

Additional Information

  • React Native version: 0.31
  • Platform(s) (iOS, Android, or both?): [android]
  • Operating System (macOS, Linux, or Windows?): [mac]

Issue Analytics

  • State:closed
  • Created 7 years ago
  • Reactions:6
  • Comments:28 (3 by maintainers)

github_iconTop GitHub Comments

6reactions
titianqxcommented, Apr 14, 2018
componentWillMount(){
    this._panResponder = PanResponder.create({
      onMoveShouldSetResponderCapture: () => true,
      onMoveShouldSetPanResponderCapture: () => true,
      onPanResponderGrant: (e, gestureState) => {
        this.fScroll.setNativeProps({ scrollEnabled: false })
      },
      onPanResponderMove: () => {

      },
      onPanResponderTerminationRequest: () => true,
      onPanResponderRelease: () => {
        this.fScroll.setNativeProps({ scrollEnabled: true })
      },
    })
} 

<ScrollView ref={(e) => { this.fScroll = e }} >    
  <ScrollView 
    {...this._panResponder.panHandlers}
    onScrollEndDrag={() => this.fScroll.setNativeProps({ scrollEnabled: true })} >
  </ScrollView>
</ScrollView>

#1046

4reactions
ericnakagawacommented, Jan 12, 2017

@falltodis I’m closing this issue since there hasn’t been any activity on it in a couple months. If this issue still persists reopen and I’ll track down someone to review.

Read more comments on GitHub >

github_iconTop Results From Across the Web

android - ScrollView not scrolling at all - Stack Overflow
Answer: the ScrollView is not working when used as the root element of an XML layout. It has to be wrapped inside a...
Read more >
Scroll view not scrolling on Android | The Draftbit Community
I've found why this is happening: the scroll view works when the screen config is set to "NOT SCROLLABLE". When the screen is...
Read more >
Scroll View Problem. Solution of Scroll View in Android Studio ...
ScrollView #Anytechnology #Scrollviewproblem_SolutionProblem as: you add the scroll view but your all screen element is goneIn this video i ...
Read more >
ScrollView doesn't work properly on Android. #7590 - GitHub
After clicking the button the button is gone and no scrolling is possible. This happens on Android and iOS but is fine on...
Read more >
ScrollView - React Native
When true , the scroll view automatically centers the content when the content is smaller than the scroll view bounds; when the content...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found