mirror of
https://codeberg.org/comaps/comaps
synced 2025-12-25 23:33:53 +00:00
[android] Add content descriptions to android elements
Signed-off-by: clover sage <codeberg.evidence981@simplelogin.com>
This commit is contained in:
@@ -52,7 +52,7 @@ public class LayerBottomSheetItem
|
||||
case SUBWAY:
|
||||
disabledResource = R.attr.subwayMenuDisabled;
|
||||
enabledResource = R.attr.subwayMenuEnabled;
|
||||
buttonTextResource = R.string.button_layer_subway;
|
||||
buttonTextResource = R.string.subway;
|
||||
break;
|
||||
case ISOLINES:
|
||||
disabledResource = R.attr.isoLinesMenuDisabled;
|
||||
|
||||
@@ -43,6 +43,7 @@ public class LayersAdapter extends RecyclerView.Adapter<LayerHolder>
|
||||
boolean isEnabled = item.getMode().isEnabled(context);
|
||||
|
||||
holder.mButton.setSelected(isEnabled);
|
||||
holder.mButton.setContentDescription(context.getString(item.getTitle()));
|
||||
holder.mTitle.setSelected(isEnabled);
|
||||
holder.mTitle.setText(item.getTitle());
|
||||
boolean isNewLayer = SharedPropertiesUtils.shouldShowNewMarkerForLayerMode(context,
|
||||
|
||||
@@ -113,6 +113,7 @@ public final class PlacePageButtons extends Fragment implements Observer<List<Pl
|
||||
TextView title = parent.findViewById(R.id.title);
|
||||
|
||||
title.setText(current.getTitle());
|
||||
parent.setContentDescription(getString(current.getTitle()));
|
||||
@AttrRes final int tint = current.getType() == ButtonType.BOOKMARK_DELETE
|
||||
? R.attr.iconTintActive
|
||||
: R.attr.iconTint;
|
||||
|
||||
Reference in New Issue
Block a user