Android FragmentTransaction replace()

mTransaction.replace(R.id.framelayout, fragment).commit();

replace 内部执行的是 先remove 之前的 fragment add新的 fragment.

你可能感兴趣的:(Android FragmentTransaction replace())