java.lang.IllegalStateException: Failure saving state: active has cleared index in fragment
问题 First, my app has structure like this: SpashActivity -> MainActivity -> switching between many fragments My app use SlideMenu to switch between fragments. I have to use attach instead of replace to keep fragment state. It's look like: public void switchContent(int index, String fragmentTag) { FragmentManager fragmentManager = getSupportFragmentManager(); FragmentTransaction transaction = fragmentManager.beginTransaction(); if (fragmentManager.findFragmentByTag(fragmentTag) != mContent) { if (