Add content description to screensaver customization button am: ca65b6e5ba
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Settings/+/21268649 Change-Id: Ia8a22edd2cdea63042d535d6ad7ebe3ae27d125d Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
This commit is contained in:
@@ -14452,6 +14452,8 @@
|
||||
|
||||
<!-- Button to customize the screensaver [CHAR LIMIT=20] -->
|
||||
<string name="customize_button_title">Customize</string>
|
||||
<!-- The content description for accessibility tools of the customize button. It specifies which screensaver the user is customizing [CHAR LIMIT=NONE] -->
|
||||
<string name="customize_button_description">Customize <xliff:g id="screensaver_name" example="Art Gallery">%1$s</xliff:g></string>
|
||||
|
||||
<!-- Dialog body text used to explain a reboot is required after enabling freeform support for
|
||||
it to work [CHAR LIMIT=none] -->
|
||||
|
@@ -129,6 +129,9 @@ public class DreamAdapter extends RecyclerView.Adapter<RecyclerView.ViewHolder>
|
||||
// This must be called AFTER itemView.setSelected above, in order to keep the
|
||||
// customize button in an unselected state.
|
||||
mCustomizeButton.setSelected(false);
|
||||
mCustomizeButton.setContentDescription(
|
||||
mContext.getResources().getString(R.string.customize_button_description,
|
||||
item.getTitle()));
|
||||
}
|
||||
|
||||
setEnabledStateOnViews(itemView, mEnabled);
|
||||
|
Reference in New Issue
Block a user