int menuIndex = 1;
arguments.putInt("expand_menu_type", menuIndex);
BFragment fragment = new BFragment();
fragment.setArguments(arguments);
getFragmentManager().beginTransaction().replace(R.id.expand_menu, fragment, BFragment.class.getName()).addToBackStack(BFragment.class.getName()).commitAllowingStateLoss();
//點擊widget id R.id.expand_menu
//欲前往Fragment BFragment
//Class Name為BFragment.class.getName()
//
沒有留言:
張貼留言