title: Trying to add nav drawer button to the app bar
body: <p>I'm following <a href="https://developer.android.com/training/implementing-navigation/nav-drawer#java" rel="nofollow noreferrer">this tutorial</a></p>
  
  <p>I'm stuck at the bit where I'm trying to add the button to the app bar.</p>
  
  <p>When I swipe right, the navigation drawer appears, so thats working.  Its just the button in the bar that I'm having problems with, When I add the <code>v7.widget.Toolbar</code> into the XML under FrameLayout it ruins the layout.</p>
  
  <p>Orginally in my XML I just had a constraint layout, with a Scrollview as a child and inside that a LinearView (vertical).</p>
  
  <p>However I cant get my head around why this isnt working:</p>
  
  <pre><code>&lt;?xml version="1.0" encoding="utf-8"?&gt;
  &lt;!-- Use DrawerLayout as root container for activity --&gt;
  &lt;android.support.v4.widget.DrawerLayout xmlns:android="http://schemas.android.com/apk/res/android"
      xmlns:app="http://schemas.android.com/apk/res-auto"
      android:id="@+id/drawer_layout"
      android:layout_width="match_parent"
      android:layout_height="match_parent"
      android:fitsSystemWindows="true"&gt;
  
  
      &lt;!-- Container for contents of drawer - use NavigationView to make configuration easier --&gt;
      &lt;android.support.design.widget.NavigationView
          android:id="@+id/nav_view"
          android:layout_width="wrap_content"
          android:layout_height="match_parent"
          android:layout_gravity="start"
          android:fitsSystemWindows="true"
          app:menu="@menu/drawer_view"
          app:headerLayout="@layout/nav_header" /&gt;
  
      &lt;!-- Layout to contain contents of main body of screen (drawer will slide over this) --&gt;
      &lt;FrameLayout
          android:id="@+id/content_frame"
          android:layout_width="match_parent"
          android:layout_height="match_parent" &gt;
  
  
          &lt;android.support.v7.widget.Toolbar
              android:id="@+id/toolbar"
              android:layout_width="match_parent"
              android:layout_height="?attr/actionBarSize"
              android:background="?attr/colorPrimary"
              android:theme="@style/ThemeOverlay.AppCompat.ActionBar" /&gt;
  
          &lt;ScrollView
              android:layout_width="match_parent"
              android:layout_height="match_parent"&gt;
  
  
  
              &lt;LinearLayout
                  android:id="@+id/seeds_container"
                  android:layout_width="match_parent"
                  android:layout_height="match_parent"
                  android:layout_marginBottom="8dp"
                  android:layout_marginEnd="8dp"
                  android:layout_marginLeft="8dp"
                  android:layout_marginRight="8dp"
                  android:layout_marginStart="8dp"
                  android:layout_marginTop="16dp"
                  android:background="@drawable/customborder"
                  android:orientation="vertical"
                  app:layout_constraintBottom_toBottomOf="parent"
                  app:layout_constraintEnd_toEndOf="parent"
                  app:layout_constraintStart_toStartOf="parent"
                  app:layout_constraintTop_toTopOf="parent"&gt;&lt;/LinearLayout&gt;
          &lt;/ScrollView&gt;
  
      &lt;/FrameLayout&gt;
  </code></pre>
  
  <p></p>
  
  <p>When I run this the top bar just seems to overtake the entire window and the color disappears and the button is not clickable because the <code>LinearLayout</code> is over the top of it.  Where am I going wrong?</p>