Code example for FragmentActivity

Methods: onBackPressed

0
    if (!isLeftShowing) {
      root.showLeft();
      isLeftShowing=true;
    } 
    else { 
      super.onBackPressed(); 
    } 
  } 
 
  @Override 
  protected void onSaveInstanceState(Bundle outState) {
    super.onSaveInstanceState(outState);
     
    outState.putStringArrayList(KEY_MIDDLE_CONTENTS, middleContents);
  } 
   
  @Override 
  protected void onRestoreInstanceState(Bundle inState) {
    middleContents=inState.getStringArrayList(KEY_MIDDLE_CONTENTS);
  }