Added scrollTo method to ListView

Summary: Closes https://github.com/facebook/react-native/pull/4781

Reviewed By: svcscm

Differential Revision: D2803479

Pulled By: mkonicek

fb-gh-sync-id: 7da41eb0bdfb0f90b4f81d1006eaf00446820827
This commit is contained in:
Emilio Rodriguez 2016-01-06 10:24:48 -08:00 committed by facebook-github-bot-6
parent 385fa00af8
commit 33e05a11f0
1 changed files with 4 additions and 0 deletions

View File

@ -236,6 +236,10 @@ var ListView = React.createClass({
this.refs[SCROLLVIEW_REF].getScrollResponder();
},
scrollTo: function(destY, destX) {
this.getScrollResponder().scrollResponderScrollTo(destX || 0, destY || 0);
},
setNativeProps: function(props) {
this.refs[SCROLLVIEW_REF].setNativeProps(props);
},