title: ViewPager fragments, not attached?
body: <p>I have a problem with ViewPager. It won't display any of my pre-definied fragments, it just displays a black screen. The onCreateView method is called from inside the fragments. </p>
  
  <pre><code>public class TestViewPager extends FragmentActivity {
      @Override
      public void onCreate(Bundle bundle) {
          super.onCreate(bundle);
          setContentView(R.layout.test_view_pager);
      }
  }
  
  public class TestFragment extends Fragment {
  
      @Override
      public void onCreate(Bundle savedInstanceState) {
          super.onCreate(savedInstanceState);
      }
  
      @Override
      public View onCreateView(LayoutInflater inflater, ViewGroup container,
              Bundle savedInstanceState) {
          View fragmentView = inflater.inflate(R.layout.entry_layout, container, false);
          return fragmentView;
      }
  }
  
  &lt;android.support.v4.view.ViewPager xmlns:android="http://schemas.android.com/apk/res/android"
      android:layout_width="fill_parent"
      android:layout_height="fill_parent"&gt;
  
      &lt;fragment 
          class="com.test.TestFragment"
          android:id="@+id/embedded1"
          android:layout_width="match_parent"
          android:layout_height="match_parent"/&gt;
  
      &lt;fragment 
          class="com.test.AnotherTestfragment"
          android:id="@+id/embedded2"
          android:layout_width="match_parent"
          android:layout_height="match_parent"/&gt;   
  &lt;/android.support.v4.view.ViewPager&gt;
  </code></pre>