我的主要版面有2个片段;
来自主要
的textview片段1:
textview="1";
FragmentTransaction fTrans;
fTrans = getFragmentManager().beginTransaction();
fTrans.replace(R.id.frameLayout, fragment2);
fTrans.addToBackStack(null); //i tried to delete this and overload onPressBack, but I can't
fTrans.setTransition(FragmentTransaction.TRANSIT_FRAGMENT_OPEN);
fTrans.commit();
片段2中的我设置了textview="2";
并按返回,
我想取消我在 fragment2 中完成的所有工作,并设置textview="1";