From 678235122bb61304a36731e7a4ab1f4ad666980f Mon Sep 17 00:00:00 2001
From: Scott Main
Date: Thu, 16 May 2013 10:41:15 -0700
Subject: [PATCH] add links to nav drawer icons
Change-Id: I97cf24421542d70402488f8c193c7bcc7ef7edd5
---
.../implementing-navigation/nav-drawer.jd | 17 +++++++++++++++--
1 file changed, 15 insertions(+), 2 deletions(-)
diff --git a/docs/html/training/implementing-navigation/nav-drawer.jd b/docs/html/training/implementing-navigation/nav-drawer.jd
index 81c792d92ea09..527d570dfe0bf 100644
--- a/docs/html/training/implementing-navigation/nav-drawer.jd
+++ b/docs/html/training/implementing-navigation/nav-drawer.jd
@@ -25,6 +25,12 @@ trainingnavtop=true
NavigationDrawer.zip
+
+
@@ -296,6 +302,8 @@ it with its constructor, which requires the following arguments:
The {@link android.app.Activity} hosting the drawer.
The {@link android.support.v4.widget.DrawerLayout}.
A drawable resource to use as the drawer indicator.
+ Download the standard navigation icons (available for both dark and light themes).
A String resource to describe the "open drawer" action (for accessibility).
A String resource to describe the "close drawer" action (for accessibility).
@@ -315,8 +323,13 @@ public class MainActivity extends Activity {
...
mDrawerLayout = (DrawerLayout) findViewById(R.id.drawer_layout);
- mDrawerToggle = new ActionBarDrawerToggle(this, mDrawerLayout,
- R.drawable.ic_drawer, R.string.drawer_open, R.string.drawer_close) {
+ mDrawerToggle = new ActionBarDrawerToggle(
+ this, /* host Activity */
+ mDrawerLayout, /* DrawerLayout object */
+ R.drawable.ic_drawer, /* nav drawer icon to replace 'Up' caret */
+ R.string.drawer_open, /* "open drawer" description */
+ R.string.drawer_close /* "close drawer" description */
+ ) {
/** Called when a drawer has settled in a completely closed state. */
public void onDrawerClosed(View view) {