navigator.getCurrentRoutes()
Summary: According to our talk with @ericvicenti about `renderScene` arguments Closes https://github.com/facebook/react-native/pull/553 Github Author: Kureev Alexey <kureev-mail@ya.ru> Test Plan: Imported from GitHub, without a `Test Plan:` line.
This commit is contained in:
parent
de8a370e02
commit
8a8244a583
|
@ -318,6 +318,7 @@ var Navigator = React.createClass({
|
||||||
popToRoute: this.popToRoute,
|
popToRoute: this.popToRoute,
|
||||||
popToTop: this.popToTop,
|
popToTop: this.popToTop,
|
||||||
parentNavigator: this.props.navigator,
|
parentNavigator: this.props.navigator,
|
||||||
|
getCurrentRoutes: this.getCurrentRoutes,
|
||||||
// We want to bubble focused routes to the top navigation stack. If we
|
// We want to bubble focused routes to the top navigation stack. If we
|
||||||
// are a child navigator, this allows us to call props.navigator.on*Focus
|
// are a child navigator, this allows us to call props.navigator.on*Focus
|
||||||
// of the topmost Navigator
|
// of the topmost Navigator
|
||||||
|
@ -998,6 +999,10 @@ var Navigator = React.createClass({
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
|
getCurrentRoutes: function() {
|
||||||
|
return this.state.routeStack;
|
||||||
|
},
|
||||||
|
|
||||||
_onItemRef: function(itemId, ref) {
|
_onItemRef: function(itemId, ref) {
|
||||||
this._itemRefs[itemId] = ref;
|
this._itemRefs[itemId] = ref;
|
||||||
var itemIndex = this.state.idStack.indexOf(itemId);
|
var itemIndex = this.state.idStack.indexOf(itemId);
|
||||||
|
|
Loading…
Reference in New Issue