Instrumentation test for native listview component.
Differential Revision: D2549707 fb-gh-sync-id: c9ff379383853c198274778e99a72b313d9dbda9
This commit is contained in:
parent
3d40d622f9
commit
f47e8ac6a1
|
@ -12,6 +12,8 @@ var ScrollView = require('ScrollView');
|
|||
|
||||
var requireNativeComponent = require('requireNativeComponent');
|
||||
|
||||
var INNERVIEW = 'InnerView';
|
||||
|
||||
/**
|
||||
* Wrapper around android native recycler view.
|
||||
*
|
||||
|
@ -63,6 +65,10 @@ var RecyclerViewBackedScrollView = React.createClass({
|
|||
return this;
|
||||
},
|
||||
|
||||
getInnerViewNode: function(): any {
|
||||
return React.findNodeHandle(this.refs[INNERVIEW]);
|
||||
},
|
||||
|
||||
render: function() {
|
||||
var props = {
|
||||
...this.props,
|
||||
|
@ -81,6 +87,7 @@ var RecyclerViewBackedScrollView = React.createClass({
|
|||
onResponderReject: this.scrollResponderHandleResponderReject,
|
||||
onScroll: this.scrollResponderHandleScroll,
|
||||
style: ([{flex: 1}, this.props.style]: ?Array<any>),
|
||||
ref: INNERVIEW,
|
||||
};
|
||||
return (
|
||||
<NativeAndroidRecyclerView {...props}/>
|
||||
|
|
Loading…
Reference in New Issue