title: Android retain Fragment not visible after orientation change
body: <p>I try to reduce my view hierarchy and use the android.R.id.content view to add a Fragment which use setRetainInstance( true ) to keep its instance alive.</p>
  
  <p>My activity is very simple</p>
  
  <pre><code>public class MainActivity extends ActionBarActivity {
  
      @Override
      protected void onCreate( final Bundle savedInstanceState ) {
          super.onCreate( savedInstanceState );
  
          // ensure that the view is available if we add the fragment
          findViewById( android.R.id.content ).post( new Runnable(){
              @Override
              public void run() {
                  // add the fragment only once to manager
                  if( savedInstanceState == null ) {
                      getSupportFragmentManager()
                          .beginTransaction()
                          .add( android.R.id.content, new LoginFragment() )
                          .commit();
                  }
              }
          } );
      }
  }
  </code></pre>
  
  <p>The Fragment create its own view and use the setRetainInstance(true) method in onCreate().
  My problem is that after a orientation change my fragment isn't re-added to the activity and the activity is empty.</p>