From d61f9057b6c17627272553ab84041e60b9239a8d Mon Sep 17 00:00:00 2001 From: Bradlee Speice Date: Mon, 21 Jul 2014 20:42:21 -0400 Subject: [PATCH] Download now using the new Navbar --- .../activity/downloader/DownloadNavDrawerFragment.java | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/app/src/main/java/org/bspeice/minimalbible/activity/downloader/DownloadNavDrawerFragment.java b/app/src/main/java/org/bspeice/minimalbible/activity/downloader/DownloadNavDrawerFragment.java index bed11f9..7bb77e6 100644 --- a/app/src/main/java/org/bspeice/minimalbible/activity/downloader/DownloadNavDrawerFragment.java +++ b/app/src/main/java/org/bspeice/minimalbible/activity/downloader/DownloadNavDrawerFragment.java @@ -8,8 +8,10 @@ import android.widget.AdapterView; import android.widget.ArrayAdapter; import android.widget.ListView; +import org.bspeice.minimalbible.Injector; import org.bspeice.minimalbible.R; import org.bspeice.minimalbible.activity.BaseNavigationDrawerFragment; +import org.bspeice.minimalbible.activity.NavDrawerAdapter; import org.crosswire.jsword.book.BookCategory; import java.util.List; @@ -25,7 +27,7 @@ public class DownloadNavDrawerFragment extends BaseNavigationDrawerFragment { @Override public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) { - ((DownloadActivity)getActivity()).inject(this); + ((Injector)getActivity()).inject(this); mDrawerListView = (ListView) inflater.inflate( R.layout.fragment_navigation_drawer, container, false); @@ -38,9 +40,8 @@ public class DownloadNavDrawerFragment extends BaseNavigationDrawerFragment { } }); - mDrawerListView.setAdapter(new ArrayAdapter(getActionBar() - .getThemedContext(), android.R.layout.simple_list_item_1, - android.R.id.text1, validCategories)); + mDrawerListView.setAdapter(new NavDrawerAdapter(getActivity(), + validCategories)); mDrawerListView.setItemChecked(mCurrentSelectedPosition, true); return mDrawerListView; }