Skip to content

Commit

Permalink
Fix Navigator transition.
Browse files Browse the repository at this point in the history
Summary: Fix the bug reported as #8071

Reviewed By: fkgozali

Differential Revision: D3553062

fbshipit-source-id: 286feddc268f51c0d9005a8831640c5e6af4880e
  • Loading branch information
Hedger Wang authored and Facebook Github Bot 1 committed Jul 13, 2016
1 parent f317b9f commit 5189c94
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions Libraries/CustomComponents/Navigator/Navigator.js
Original file line number Diff line number Diff line change
Expand Up @@ -501,13 +501,13 @@ var Navigator = React.createClass({
},

_transitionTo: function(destIndex, velocity, jumpSpringTo, cb) {
if (
destIndex === this.state.presentedIndex &&
this.state.transitionQueue.length === 0
) {
if (this.state.presentedIndex === destIndex) {
cb && cb();
return;
}

if (this.state.transitionFromIndex !== null) {
// Navigation is still transitioning, put the `destIndex` into queue.
this.state.transitionQueue.push({
destIndex,
velocity,
Expand Down

0 comments on commit 5189c94

Please sign in to comment.