title: Android L - Activity with Fragment display error (only the fragment is displayed)
body: <p>As the title says, when I try to make a simple activity with a fragment, all I get on screen is the fragment content. The status bar, the background, everything is missing. <a href="https://www.youtube.com/watch?v=E9v7KV7y-SU" rel="nofollow">I made a video to show what happens [0:47]</a>. If you watch the video, the app works on KitKat, but fails on Lollipop. I'm not sure if this is a L Preview failure.</p>
  
  <p>The code for my <code>MainActivity</code> is generated by Android Studio:</p>
  
  <pre><code>public class MainActivity extends Activity
  {
      @Override
      protected void onCreate(Bundle prevState)
      {
          super.onCreate(prevState);
          setContentView(R.layout.activity_main);
  
          if(prevState == null)
              getFragmentManager().beginTransaction().replace(R.id.main_fragment, new PlaceholderFragment()).commit();
      }
  
  
      @Override
      public boolean onCreateOptionsMenu(Menu menu)
      {
          // Inflate the menu; this adds items to the action bar if it is present.
          getMenuInflater().inflate(R.menu.menu_main, menu);
          return true;
      }
  
      @Override
      public boolean onOptionsItemSelected(MenuItem item)
      {
          // Handle action bar item clicks here. The action bar will
          // automatically handle clicks on the Home/Up button, so long
          // as you specify a parent activity in AndroidManifest.xml.
          int id = item.getItemId();
  
          //noinspection SimplifiableIfStatement
          if(id == R.id.action_settings)
              return true;
  
          return super.onOptionsItemSelected(item);
      }
  
      /**
       * A placeholder fragment containing a simple view.
       */
      public static class PlaceholderFragment extends Fragment
      {
  
          public PlaceholderFragment()
          {
          }
  
          @Override
          public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle prevState)
          {
              View rootView = inflater.inflate(R.layout.fragment_main, container, false);
              return rootView;
          }
      }
  }
  </code></pre>
  
  <p>My <code>.xml</code> file is just a <code>FrameLayout</code> with a <code>fragment</code> element inside of it. It's replaced in the <code>onCreate(Bundle prevState)</code> method as shown above.</p>
  
  <p>Here's my <code>MainActivity</code> XML file:</p>
  
  <pre><code>&lt;FrameLayout
      xmlns:android="http://schemas.android.com/apk/res/android"
      xmlns:tools="http://schemas.android.com/tools"
      android:id="@+id/main_container"
      android:layout_width="match_parent"
      android:layout_height="match_parent"
      tools:context=".MainActivity"
      tools:ignore="MergeRootFrame" &gt;
  
      &lt;fragment
          android:id="@+id/main_fragment"
          android:name="me.kworden.dart.fragment.MainFragment"
          android:layout_width="fill_parent"
          android:layout_height="fill_parent"
          tools:layout="@layout/fragment_main" /&gt;
  
  &lt;/FrameLayout&gt;
  </code></pre>
  
  <p>My styles look like this:</p>
  
  <pre><code>&lt;?xml version="1.0" encoding="utf-8"?&gt;
  &lt;resources&gt;
      &lt;style name="AppTheme" parent="android:Theme.Material.Light.DarkActionBar"&gt;
          &lt;item name="android:colorPrimaryDark"&gt;#C40048&lt;/item&gt;
          &lt;item name="android:colorPrimary"&gt;#FF005D&lt;/item&gt;
          &lt;item name="android:colorAccent"&gt;#AEFF00&lt;/item&gt;
      &lt;/style&gt;
  &lt;/resources&gt;
  </code></pre>
  
  <p>Any ideas?</p>