From 364082e355e0ea4f39e48d8ef11b18350f4b077e Mon Sep 17 00:00:00 2001 From: alanv Date: Tue, 2 Oct 2012 17:16:18 -0700 Subject: [PATCH] Add a11y content descriptions and label mapping to Dreams. Also makes the radio button non-focusable and non-clickable, since focus and click are handled by its list item container. Clicking on top of the radio button still works as intended. Bug: 7230372 Change-Id: I0f311160b09402d882c9d35fdb51e8f19c60f522 --- res/layout/dream_info_row.xml | 9 ++++++--- res/values/strings.xml | 2 ++ 2 files changed, 8 insertions(+), 3 deletions(-) diff --git a/res/layout/dream_info_row.xml b/res/layout/dream_info_row.xml index c2d90fbc806..a2f81c619ef 100644 --- a/res/layout/dream_info_row.xml +++ b/res/layout/dream_info_row.xml @@ -54,7 +54,8 @@ android:ellipsize="end" android:singleLine="true" android:textAppearance="?android:attr/textAppearanceMedium" - android:textDirection="locale" /> + android:textDirection="locale" + android:labelFor="@android:id/button2" /> @@ -64,7 +65,9 @@ android:layout_height="match_parent" android:layout_alignParentEnd="true" android:layout_centerVertical="true" - android:duplicateParentState="true" /> + android:duplicateParentState="true" + android:clickable="false" + android:focusable="false" /> @@ -90,7 +93,7 @@ android:layout_centerVertical="true" android:layout_margin="0dip" android:background="?android:attr/selectableItemBackground" - android:contentDescription="@null" + android:contentDescription="@string/screensaver_settings_button" android:padding="8dip" android:src="@drawable/ic_bt_config" /> diff --git a/res/values/strings.xml b/res/values/strings.xml index 0d2a983f535..1f942879846 100644 --- a/res/values/strings.xml +++ b/res/values/strings.xml @@ -1793,6 +1793,8 @@ When to sleep Sleep now + + Settings Automatic brightness