diff --git a/app/src/main/java/org/bspeice/minimalbible/activity/downloader/DownloadActivity.java b/app/src/main/java/org/bspeice/minimalbible/activity/downloader/DownloadActivity.java index fd84d20..eee42fa 100644 --- a/app/src/main/java/org/bspeice/minimalbible/activity/downloader/DownloadActivity.java +++ b/app/src/main/java/org/bspeice/minimalbible/activity/downloader/DownloadActivity.java @@ -4,6 +4,7 @@ import android.content.Intent; import android.os.Bundle; import android.support.v4.app.FragmentManager; import android.support.v4.widget.DrawerLayout; +import android.support.v7.app.ActionBarDrawerToggle; import android.support.v7.widget.Toolbar; import android.view.Menu; import android.view.MenuItem; @@ -87,6 +88,14 @@ public class DownloadActivity extends BaseActivity implements setSupportActionBar(toolbar); + // Set up the hamburger menu + getSupportActionBar().setDisplayHomeAsUpEnabled(true); + getSupportActionBar().setHomeButtonEnabled(true); + ActionBarDrawerToggle toggle = new ActionBarDrawerToggle(this, drawerLayout, + toolbar, R.string.navigation_drawer_open, R.string.navigation_drawer_close); + drawerLayout.setDrawerListener(toggle); + toggle.syncState(); + navigationContent.setAdapter( new ArrayAdapter<>(this, android.R.layout.simple_list_item_1, validCategories)); diff --git a/app/src/main/java/org/bspeice/minimalbible/activity/viewer/BibleViewer.java b/app/src/main/java/org/bspeice/minimalbible/activity/viewer/BibleViewer.java index 935f894..b424738 100644 --- a/app/src/main/java/org/bspeice/minimalbible/activity/viewer/BibleViewer.java +++ b/app/src/main/java/org/bspeice/minimalbible/activity/viewer/BibleViewer.java @@ -3,6 +3,7 @@ package org.bspeice.minimalbible.activity.viewer; import android.content.Intent; import android.os.Bundle; import android.support.v4.widget.DrawerLayout; +import android.support.v7.app.ActionBarDrawerToggle; import android.support.v7.widget.Toolbar; import android.view.Menu; import android.view.MenuItem; @@ -89,7 +90,17 @@ public class BibleViewer extends BaseActivity implements Injector { ButterKnife.inject(this); setSupportActionBar(toolbar); + + // Set up the hamburger menu + getSupportActionBar().setDisplayHomeAsUpEnabled(true); + getSupportActionBar().setHomeButtonEnabled(true); + ActionBarDrawerToggle toggle = new ActionBarDrawerToggle(this, drawerLayout, + toolbar, R.string.navigation_drawer_open, R.string.navigation_drawer_close); + drawerLayout.setDrawerListener(toggle); + toggle.syncState(); + setInsetToolbar(toolbar); + bibleMenu.setBible(mainBook); bibleContent.setBook(mainBook, prefs); } diff --git a/app/src/main/res/values/styles.xml b/app/src/main/res/values/styles.xml index 35bef08..7cbbeff 100644 --- a/app/src/main/res/values/styles.xml +++ b/app/src/main/res/values/styles.xml @@ -8,6 +8,8 @@ @color/textColorPrimary @color/textColor + + @style/DrawerArrowStyle @@ -21,6 +23,11 @@ --> + +