Code example for FragmentTransaction

Methods: setCustomAnimations

0
  private void removePreviousFragment() { 
    FragmentManager fm = getSupportFragmentManager();
    int count = fm.getBackStackEntryCount();
    if (count > 0) {
    	FragmentTransaction ft = fm.beginTransaction();
      ft.setCustomAnimations(android.R.anim.slide_in_left, android.R.anim.slide_out_right, android.R.anim.slide_out_right, android.R.anim.slide_in_left);
    	//ft.hide(mCurrentFragment); 
      fm.popBackStack();
      fm.executePendingTransactions();
      if (count > 1) {
        String name = fm.getBackStackEntryAt(count-2).getName();
        mCurrentFragment = fm.findFragmentByTag(name);
      } else { 
        mCurrentFragment = null;
      } 
    } 
  } 
 
	private Uri imageUri;
	private static final int TAKE_PICTURE = 5;
Contextual code suggestions in your IDE  Get Codota for Java