title: java.lang.IllegalStateException: Can't change container ID of fragment
body: <p>I try to swap the positions of the two fragments by clicking on the button.
  First, I add tow FrameLayout in my xml file.</p>
  
  <pre><code> &lt;FrameLayout
      android:id="@+id/content_frame_small"
      android:layout_width="120dp"
      android:layout_height="200dp"
      android:layout_marginTop="50dp"
      android:layout_alignParentRight="true"
      android:clickable="true"
      android:rotation="90" /&gt;
  
  &lt;FrameLayout
      android:id="@+id/big_fragment"
      android:layout_width="match_parent"
      android:layout_height="match_parent" /&gt;
  </code></pre>
  
  <p>And then add the fragments when initView</p>
  
  <pre><code>    FragmentTransaction ft = getSupportFragmentManager().beginTransaction();
      findViewById(R.id.content_frame_small).bringToFront();
      if (mapFragment == null) {
          mapFragment = new MapFragment();
      }
      ft.addToBackStack(MapFragment.TAG);
      ft.add(R.id.content_frame_small, mapFragment, MapFragment.TAG);
      if (cameraPreviewFragment == null) {
          cameraPreviewFragment = new CameraPreviewFragment();
      }
      ft.addToBackStack(CameraPreviewFragment.TAG);
      ft.add(R.id.big_fragment, cameraPreviewFragment, CameraPreviewFragment.TAG);
      ft.commitAllowingStateLoss();
  </code></pre>
  
  <p>But the small fragment has not been shown！I tried to swap two fragments' position, but the small ones still did not appear. And when I try to change their position by click a button it appear:</p>
  
  <pre><code>java.lang.IllegalStateException: Can't change container ID of fragment MapFragment{43138b40 #0 id=0x7f110098 MapFragment}: was 2131820696 now 2131820697
                                                                             at android.support.v4.app.BackStackRecord.doAddOp(BackStackRecord.java:406)
                                                                             at android.support.v4.app.BackStackRecord.add(BackStackRecord.java:375)
                                                                             at com.locision.ogipssampler.activity.CameraRecordActivity.onClick(CameraRecordActivity.java:321)
                                                                             at android.view.View.performClick(View.java:4444)
                                                                             at android.view.View$PerformClick.run(View.java:18457)
                                                                             at android.os.Handler.handleCallback(Handler.java:733)
                                                                             at android.os.Handler.dispatchMessage(Handler.java:95)
                                                                             at android.os.Looper.loop(Looper.java:136)
                                                                             at android.app.ActivityThread.main(ActivityThread.java:5049)
                                                                             at java.lang.reflect.Method.invokeNative(Native Method)
                                                                             at java.lang.reflect.Method.invoke(Method.java:515)
                                                                             at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:793)
                                                                             at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:609)
                                                                             at dalvik.system.NativeStart.main(Native Method)
  </code></pre>
  
  <p>Here is my code when click:</p>
  
  <pre><code> isShowMap = !isShowMap;
   FragmentTransaction ft = 
   getSupportFragmentManager().beginTransaction();
   if (mapFragment.isAdded()) {
       ft.remove(mapFragment);
    }
   if (cameraPreviewFragment.isAdded()) {
     ft.remove(cameraPreviewFragment);
   }
   ft.commitAllowingStateLoss();
  
   getSupportFragmentManager().executePendingTransactions();
   ft = getSupportFragmentManager().beginTransaction();
   if (isShowMap) {
       mapFragment.showLogo();
       ft.add(R.id.big_fragment, mapFragment, MapFragment.TAG);
       ft.add(R.id.content_frame_small, cameraPreviewFragment, 
       CameraPreviewFragment.TAG);
    } else {
        mapFragment.disapperLogo();
        ft.add(R.id.big_fragment, cameraPreviewFragment, CameraPreviewFragment.TAG);
        ft.add(R.id.content_frame_small, mapFragment, MapFragment.TAG);
        cameraPreviewFragment.loadView(cameraManager)
    }
    ft.commitAllowingStateLoss();
  </code></pre>
  
  <p>It seems</p>