From c7c384b4f6e99c69f1eb2be6cfc5693ffc803d71 Mon Sep 17 00:00:00 2001 From: Alan Viverette Date: Mon, 5 Aug 2013 14:28:14 -0700 Subject: [PATCH] Add RTL support in Support4Demos manifest, fix DrawerLayout sample Change-Id: I1152ad6e49a1b1dc88a70f701bf7ed2fe882e242 --- samples/Support4Demos/AndroidManifest.xml | 3 ++- samples/Support4Demos/res/layout/drawer_layout.xml | 14 +++++++------- samples/Support4Demos/res/values/strings.xml | 2 +- .../supportv4/widget/DrawerLayoutActivity.java | 2 +- 4 files changed, 11 insertions(+), 10 deletions(-) diff --git a/samples/Support4Demos/AndroidManifest.xml b/samples/Support4Demos/AndroidManifest.xml index 1b015f10e..9d5ea135c 100644 --- a/samples/Support4Demos/AndroidManifest.xml +++ b/samples/Support4Demos/AndroidManifest.xml @@ -36,7 +36,8 @@ + android:hardwareAccelerated="true" + android:supportsRtl="true"> diff --git a/samples/Support4Demos/res/layout/drawer_layout.xml b/samples/Support4Demos/res/layout/drawer_layout.xml index 2ab0b1abe..375c8027a 100644 --- a/samples/Support4Demos/res/layout/drawer_layout.xml +++ b/samples/Support4Demos/res/layout/drawer_layout.xml @@ -37,15 +37,15 @@ android:text="@string/drawer_layout_summary" android:textAppearance="?android:attr/textAppearanceMedium"/> - - + diff --git a/samples/Support4Demos/res/values/strings.xml b/samples/Support4Demos/res/values/strings.xml index 5860ccccf..8d14c3275 100644 --- a/samples/Support4Demos/res/values/strings.xml +++ b/samples/Support4Demos/res/values/strings.xml @@ -157,7 +157,7 @@ Widget/Drawer layout - This activity illustrates the use of sliding drawers. The drawer may be pulled out from the left edge with an edge swipe. If this demo is running on Ice Cream Sandwich or newer you may tap the icon at the left side of the action bar to open the drawer as well. + This activity illustrates the use of sliding drawers. The drawer may be pulled out from the starting edge, which is left on left-to-right locales, with an edge swipe. If this demo is running on Ice Cream Sandwich or newer you may tap the icon at the starting side of the action bar to open the drawer as well. Open navigation drawer Close navigation drawer diff --git a/samples/Support4Demos/src/com/example/android/supportv4/widget/DrawerLayoutActivity.java b/samples/Support4Demos/src/com/example/android/supportv4/widget/DrawerLayoutActivity.java index ce311ccc0..7b88faa2e 100644 --- a/samples/Support4Demos/src/com/example/android/supportv4/widget/DrawerLayoutActivity.java +++ b/samples/Support4Demos/src/com/example/android/supportv4/widget/DrawerLayoutActivity.java @@ -83,7 +83,7 @@ public class DrawerLayoutActivity extends Activity { setContentView(R.layout.drawer_layout); mDrawerLayout = (DrawerLayout) findViewById(R.id.drawer_layout); - mDrawer = (ListView) findViewById(R.id.left_drawer); + mDrawer = (ListView) findViewById(R.id.start_drawer); mContent = (TextView) findViewById(R.id.content_text); mDrawerLayout.setDrawerListener(new DemoDrawerListener());