title: change burger icon side for nav drawer
body: <p>I used a Android Studio Template for Side menu drawer.</p>
  
  <p>Problem : I want the whole drawer to appear on right. </p>
  
  <p>Progress : I can change the android:layout_gravity to "end" for drawer layout, but i cannot move the three-line-icon (also called shelf, burger or Navigation Drawer icon) in ActionBar to the right side.</p>
  
  <p>Visual source to maybe provide better understanding of my problem:
  <a href="https://i.stack.imgur.com/eu8KA.jpg" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/eu8KA.jpg" alt="Drawer is on right, but not the burger icon"></a></p>
  
  <p>Here comes the code :</p>
  
  <p>Drawer activity (Lecture_graph.java) :</p>
  
  <pre><code>public class Lectures_graph extends AppCompatActivity implements course_list.OnFragmentInteractionListener, lectures_graph.OnFragmentInteractionListener{
  
      private AppBarConfiguration mAppBarConfiguration;
  
      @Override
      protected void onCreate(Bundle savedInstanceState) {
          super.onCreate(savedInstanceState);
  
          setContentView(R.layout.activity_lectures_graph);
          Toolbar toolbar = findViewById(R.id.toolbar);
          setSupportActionBar(toolbar);
          DrawerLayout drawer = findViewById(R.id.drawer_layout);
          NavigationView navigationView = findViewById(R.id.nav_view);
          // Passing each menu ID as a set of Ids because each
          // menu should be considered as top level destinations.
          mAppBarConfiguration = new AppBarConfiguration.Builder(
                  R.id.nav_course_list, R.id.nav_lectures_greph)
                  .setDrawerLayout(drawer)
                  .build();
          NavController navController = Navigation.findNavController(this, R.id.nav_host_fragment);
          NavigationUI.setupActionBarWithNavController(this, navController, mAppBarConfiguration);
          NavigationUI.setupWithNavController(navigationView, navController);
      }
  
      @Override
      public boolean onSupportNavigateUp() {
          NavController navController = Navigation.findNavController(this, R.id.nav_host_fragment);
          return NavigationUI.navigateUp(navController, mAppBarConfiguration)
                  || super.onSupportNavigateUp();
      }
  
      @Override
      public void onFragmentInteraction(Uri uri) {
  
      }
  }
  </code></pre>
  
  <p>XML for this activity (activity_lecture_graph.xml) :</p>
  
  <pre><code>    &lt;?xml version="1.0" encoding="utf-8"?&gt;
      &lt;androidx.drawerlayout.widget.DrawerLayout xmlns:android="http://schemas.android.com/apk/res/android"
          xmlns:app="http://schemas.android.com/apk/res-auto"
          xmlns:tools="http://schemas.android.com/tools"
          android:id="@+id/drawer_layout"
          android:layout_width="match_parent"
          android:layout_height="match_parent"
          android:fitsSystemWindows="true"
  //this lets drawer to be on right
          tools:openDrawer="end"&gt;
  
          &lt;include
              layout="@layout/app_bar_lectures_graph"
              android:layout_width="match_parent"
              android:layout_height="match_parent" /&gt;
  
          &lt;com.google.android.material.navigation.NavigationView
              android:id="@+id/nav_view"
              android:layout_width="wrap_content"
              android:layout_height="match_parent"
              android:layout_gravity="start"
              android:background="#fff"
              android:fitsSystemWindows="true"
              app:headerLayout="@layout/nav_header_lectures_graph"
              app:menu="@menu/activity_lectures_graph_drawer"
  //this allows drawer to be on right
  android:layout_gravity="end" /&gt;
  
      &lt;/androidx.drawerlayout.widget.DrawerLayout&gt;
  </code></pre>
  
  <p>app bar layout (app_bar_lectures_graph.xml) :</p>
  
  <pre><code> &lt;?xml version="1.0" encoding="utf-8"?&gt;
  &lt;androidx.coordinatorlayout.widget.CoordinatorLayout xmlns:android="http://schemas.android.com/apk/res/android"
      xmlns:app="http://schemas.android.com/apk/res-auto"
      xmlns:tools="http://schemas.android.com/tools"
      android:layout_width="match_parent"
      android:layout_height="match_parent"
      tools:context=".systems.lectures.Lectures_graph"&gt;
  
      &lt;com.google.android.material.appbar.AppBarLayout
          android:layout_width="match_parent"
          android:layout_height="wrap_content"
          android:theme="@style/AppTheme.AppBarOverlay"&gt;
  
          &lt;androidx.appcompat.widget.Toolbar
              android:id="@+id/toolbar"
              android:layout_width="match_parent"
              android:layout_height="?attr/actionBarSize"
              android:background="?attr/colorPrimary"
              app:popupTheme="@style/AppTheme.PopupOverlay" /&gt;
  
      &lt;/com.google.android.material.appbar.AppBarLayout&gt;
  
      &lt;include layout="@layout/content_lectures_graph" /&gt;
  
  &lt;/androidx.coordinatorlayout.widget.CoordinatorLayout&gt;
  </code></pre>
  
  <p>Drawer xml (activity_lectures_graph_drawer.xml) : </p>
  
  <pre><code>&lt;?xml version="1.0" encoding="utf-8"?&gt;
  &lt;androidx.coordinatorlayout.widget.CoordinatorLayout xmlns:android="http://schemas.android.com/apk/res/android"
      xmlns:app="http://schemas.android.com/apk/res-auto"
      xmlns:tools="http://schemas.android.com/tools"
      android:layout_width="match_parent"
      android:layout_height="match_parent"
      tools:context=".systems.lectures.Lectures_graph"&gt;
  
      &lt;com.google.android.material.appbar.AppBarLayout
          android:layout_width="match_parent"
          android:layout_height="wrap_content"
          android:theme="@style/AppTheme.AppBarOverlay"&gt;
  
          &lt;androidx.appcompat.widget.Toolbar
              android:id="@+id/toolbar"
              android:layout_width="match_parent"
              android:layout_height="?attr/actionBarSize"
              android:background="?attr/colorPrimary"
              app:popupTheme="@style/AppTheme.PopupOverlay" /&gt;
  
      &lt;/com.google.android.material.appbar.AppBarLayout&gt;
  
      &lt;include layout="@layout/content_lectures_graph" /&gt;
  
  &lt;/androidx.coordinatorlayout.widget.CoordinatorLayout&gt;
  </code></pre>
  
  <p>Will be thankful for any help.</p>