title: Change TabNavigator tab after clicking StackNavigator's back button
body: <p>I have an application that consists of 2 navigators: the <code>RootNavigator</code> is a <code>TabNavigator</code> with 5 tabs (A, B, C, D ,E), in which one of them (C) contains a <code>StackNavigator</code>. </p>
  
  <p><strong>What I need to do is that whenever I get to the C tab and press the back button, I get navigated to the A tab.</strong></p>
  
  <p>What I'm trying to do is: [1] create and bind a function on (C) screen that will be passed to their children screens and [2] call that function everytime the back button is pressed on the first child of (C).</p>
  
  <pre><code>const PointNavigator = StackNavigator(
  {
    Camera: {
      screen: PointCamera
    },
    Code: {
      screen: PointCode,
    }
  }, {
    headerMode: 'float',
      navigationOptions: {
          headerStyle: {
              backgroundColor: '#022436',
              shadowColor: '#000',
              shadowOffset: { width: 0, height: 2 },
              shadowOpacity: 0.2,
              elevation: 4,
              position: 'relative',
          },
          headerTintColor: 'white',
      headerBackTitle: null
    }
  });
  
  class PointScreen extends Component {
    componentWillMount() {
      this.returnToHome = this.returnToHome.bind(this);
    }
  
    returnToHome() {
      this.props.navigation.navigate('Home');
    }
  
      render() {
          return (
              &lt;View style={{ flex: 1 }}&gt;
                  &lt;PointNavigator
            screenProps={ onBackPressed: this.returnToHome.bind(this) }
          /&gt;
              &lt;/View&gt;
          );
      }
  }
  
  export default PointScreen;
  </code></pre>
  
  <p>The code above represents the (C) tab with its own <code>StackNavigator</code>. The code below is the <code>navigationOptions</code> of the first child screen of (C).</p>
  
  <pre><code>static navigationOptions = ({ screenProps }) =&gt; ({
      title: 'Pontuar',
      headerLeft: (
                    &lt;HeaderBackButton
                      tintColor='white'
                      onPress={() =&gt; screenProps.onBackPressed()}
                    /&gt;
                  )
  });
  </code></pre>
  
  <p>The problem is that I can't manage to pass the function from the parent to the child navigator, always getting <code>undefined</code> error.</p>