Skip to content

Commit

Permalink
UI: Extra content descriptions for screen readers
Browse files Browse the repository at this point in the history
Via prelaunch report, hardcoded for now.
  • Loading branch information
d4rken committed Dec 6, 2023
1 parent 2f5a6b7 commit 09a1b74
Show file tree
Hide file tree
Showing 26 changed files with 67 additions and 14 deletions.
2 changes: 2 additions & 0 deletions app/src/main/res/layout/analyzer_app_fragment.xml
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,8 @@
style="@style/BaseRecyclerList"
android:layout_height="0dp"
android:clipToPadding="false"
android:contentDescription="Analyzer app details"
tools:ignore="HardcodedText"
android:paddingVertical="4dp"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toEndOf="parent"
Expand Down
4 changes: 3 additions & 1 deletion app/src/main/res/layout/analyzer_apps_fragment.xml
Original file line number Diff line number Diff line change
Expand Up @@ -17,15 +17,17 @@

<androidx.recyclerview.widget.RecyclerView
android:id="@+id/list"
android:layout_width="match_parent"
style="@style/BaseRecyclerList"
android:layout_width="match_parent"
android:layout_height="0dp"
android:clipToPadding="false"
android:contentDescription="Analyzer apps"
android:paddingVertical="4dp"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@id/toolbar"
tools:ignore="HardcodedText"
tools:listitem="@layout/analyzer_apps_vh" />

<eu.darken.sdmse.common.progress.ProgressOverlayView
Expand Down
2 changes: 2 additions & 0 deletions app/src/main/res/layout/analyzer_content_fragment.xml
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,8 @@
android:layout_height="0dp"
android:clipToPadding="false"
android:paddingVertical="4dp"
android:contentDescription="Analyzer content"
tools:ignore="HardcodedText"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
Expand Down
2 changes: 2 additions & 0 deletions app/src/main/res/layout/analyzer_device_fragment.xml
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,8 @@
style="@style/BaseRecyclerList"
android:layout_height="0dp"
android:clipToPadding="false"
android:contentDescription="Analyzer devices"
tools:ignore="HardcodedText"
android:paddingVertical="4dp"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toEndOf="parent"
Expand Down
2 changes: 2 additions & 0 deletions app/src/main/res/layout/analyzer_storage_fragment.xml
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,8 @@
android:clipToPadding="false"
android:paddingVertical="4dp"
app:layout_constraintBottom_toBottomOf="parent"
android:contentDescription="Analyzer storages"
tools:ignore="HardcodedText"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@id/toolbar"
Expand Down
8 changes: 5 additions & 3 deletions app/src/main/res/layout/appcleaner_appjunk_fragment.xml
Original file line number Diff line number Diff line change
Expand Up @@ -7,15 +7,17 @@

<androidx.recyclerview.widget.RecyclerView
android:id="@+id/list"
style="@style/BaseRecyclerList"
android:layout_width="match_parent"
android:layout_height="0dp"
android:clipToPadding="false"
android:contentDescription="App junk details"
android:paddingVertical="4dp"
tools:listitem="@layout/appcleaner_appjunk_element_header"
style="@style/BaseRecyclerList"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent" />
app:layout_constraintTop_toTopOf="parent"
tools:ignore="HardcodedText"
tools:listitem="@layout/appcleaner_appjunk_element_header" />

</androidx.constraintlayout.widget.ConstraintLayout>
4 changes: 3 additions & 1 deletion app/src/main/res/layout/appcleaner_list_fragment.xml
Original file line number Diff line number Diff line change
Expand Up @@ -23,11 +23,13 @@
android:layout_height="0dp"
android:clipToPadding="false"
android:paddingVertical="4dp"
android:contentDescription="App junk results"
tools:ignore="HardcodedText"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@id/toolbar"
tools:listitem="@layout/appcontrol_list_item" />
tools:listitem="@layout/appcleaner_list_item" />

<eu.darken.sdmse.common.progress.ProgressOverlayView
android:id="@+id/loading_overlay"
Expand Down
10 changes: 7 additions & 3 deletions app/src/main/res/layout/appcontrol_list_fragment.xml
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,8 @@
style="@style/BaseRecyclerList"
android:layout_width="match_parent"
android:layout_height="0dp"
android:contentDescription="Appcontrol apps"
tools:ignore="HardcodedText"
android:clipToPadding="false"
android:paddingVertical="4dp"
android:visibility="invisible"
Expand All @@ -52,13 +54,15 @@
android:layout_height="wrap_content"
android:layout_marginEnd="8dp"
android:background="@drawable/bg_fastscroller"
android:contentDescription="Fastscroller shortcuts"
android:padding="4dp"
android:textAppearance="@style/TextAppearance.Material3.LabelLarge"
android:textColor="?colorOnSecondaryContainer"
app:fastScrollerIconColor="?colorSecondary"
app:layout_constraintBottom_toBottomOf="@id/list"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintTop_toTopOf="@id/list" />
app:layout_constraintTop_toTopOf="@id/list"
tools:ignore="HardcodedText" />

<com.reddit.indicatorfastscroll.FastScrollerThumbView
android:id="@+id/fastscroller_thumb"
Expand Down Expand Up @@ -89,8 +93,8 @@
android:id="@+id/filterpane"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="?colorSurfaceVariant"
android:layout_gravity="end"
android:background="?colorSurfaceVariant"
android:clickable="true"
android:focusable="true"
android:focusableInTouchMode="true"
Expand Down Expand Up @@ -185,9 +189,9 @@
android:id="@+id/tag_filter_clear_action"
style="@style/Widget.Material3.Button.TextButton"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:gravity="end|center_vertical"
android:paddingEnd="8dp"
android:layout_height="wrap_content"
android:text="@string/general_show_all_action"
app:layout_constraintBottom_toBottomOf="@id/tag_filters_label"
app:layout_constraintEnd_toEndOf="parent"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,10 +22,12 @@
android:id="@+id/slider"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:contentDescription="Slider for minimum appjunk age"
app:layout_constraintBottom_toTopOf="@id/time_scale_group"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@id/slider_value" />
app:layout_constraintTop_toBottomOf="@id/slider_value"
tools:ignore="HardcodedText" />

<RadioGroup
android:id="@+id/time_scale_group"
Expand Down
2 changes: 2 additions & 0 deletions app/src/main/res/layout/corpsefinder_corpse_fragment.xml
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,8 @@
android:paddingVertical="4dp"
style="@style/BaseRecyclerList"
app:layout_constraintBottom_toBottomOf="parent"
android:contentDescription="Corpse details"
tools:ignore="HardcodedText"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent"
Expand Down
2 changes: 2 additions & 0 deletions app/src/main/res/layout/corpsefinder_list_fragment.xml
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,8 @@
android:visibility="invisible"
tools:visibility="visible"
style="@style/BaseRecyclerList"
android:contentDescription="CorpseFinder results"
tools:ignore="HardcodedText"
android:clipToPadding="false"
android:paddingVertical="4dp"
app:layout_constraintBottom_toBottomOf="parent"
Expand Down
2 changes: 2 additions & 0 deletions app/src/main/res/layout/dashboard_fragment.xml
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,8 @@
android:layout_height="match_parent"
android:clipToPadding="false"
android:paddingBottom="100dp"
android:contentDescription="Dashboard"
tools:ignore="HardcodedText"
android:visibility="invisible"
app:layout_behavior="@string/appbar_scrolling_view_behavior"
tools:itemCount="1"
Expand Down
10 changes: 6 additions & 4 deletions app/src/main/res/layout/dashboard_title_item.xml
Original file line number Diff line number Diff line change
Expand Up @@ -13,25 +13,27 @@
android:id="@+id/mascot_container"
android:layout_width="56dp"
android:layout_height="72dp"
android:contentDescription="SD Maid mascot"
app:layout_constraintBottom_toBottomOf="@id/title_container"
app:layout_constraintEnd_toStartOf="@id/title_container"
app:layout_constraintHorizontal_chainStyle="packed"
app:layout_constraintTop_toTopOf="@id/title_container">
app:layout_constraintTop_toTopOf="@id/title_container"
tools:ignore="HardcodedText">

<ImageView
android:id="@+id/mascot_rigid"
android:layout_width="wrap_content"
android:layout_height="52dp"
android:layout_gravity="center"
android:visibility="invisible"
android:src="@drawable/vector_mascot_nobroom" />
android:src="@drawable/vector_mascot_nobroom"
android:visibility="invisible" />

<com.airbnb.lottie.LottieAnimationView
android:id="@+id/mascot_animated"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:scaleType="centerCrop"
android:layout_gravity="center"
android:scaleType="centerCrop"
app:lottie_autoPlay="true"
app:lottie_fallbackRes="@drawable/splash_mascot"
app:lottie_fileName="lottie/mascot_animation_coffee_relaxed.json"
Expand Down
2 changes: 2 additions & 0 deletions app/src/main/res/layout/data_areas_fragment.xml
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,8 @@
android:layout_width="match_parent"
android:layout_height="0dp"
android:clipToPadding="false"
android:contentDescription="Data areas"
tools:ignore="HardcodedText"
style="@style/BaseRecyclerList"
android:paddingVertical="4dp"
app:layout_constraintBottom_toBottomOf="parent"
Expand Down
2 changes: 2 additions & 0 deletions app/src/main/res/layout/debug_logview_fragment.xml
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,8 @@
android:layout_width="match_parent"
android:layout_height="0dp"
android:clipToPadding="false"
android:contentDescription="Debug log"
tools:ignore="HardcodedText"
android:paddingVertical="4dp"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toEndOf="parent"
Expand Down
2 changes: 2 additions & 0 deletions app/src/main/res/layout/deduplicator_cluster_fragment.xml
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,8 @@
android:paddingVertical="4dp"
style="@style/BaseRecyclerList"
app:layout_constraintBottom_toBottomOf="parent"
android:contentDescription="Duplicate sets"
tools:ignore="HardcodedText"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent"
Expand Down
2 changes: 2 additions & 0 deletions app/src/main/res/layout/deduplicator_list_fragment.xml
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,8 @@
style="@style/BaseRecyclerList"
android:clipToPadding="false"
android:paddingVertical="4dp"
android:contentDescription="Deduplicator result"
tools:ignore="HardcodedText"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
Expand Down
2 changes: 2 additions & 0 deletions app/src/main/res/layout/exclusion_list_fragment.xml
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,8 @@
android:id="@+id/list"
style="@style/BaseRecyclerList"
android:layout_width="match_parent"
android:contentDescription="Exclusions"
tools:ignore="HardcodedText"
android:layout_height="match_parent"
android:clipToPadding="false"
android:paddingVertical="4dp"
Expand Down
2 changes: 2 additions & 0 deletions app/src/main/res/layout/scheduler_manager_fragment.xml
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,8 @@
style="@style/BaseRecyclerList"
android:layout_width="match_parent"
android:layout_height="0dp"
android:contentDescription="Schedules"
tools:ignore="HardcodedText"
android:clipToPadding="false"
android:paddingVertical="4dp"
app:layout_constraintBottom_toBottomOf="parent"
Expand Down
2 changes: 2 additions & 0 deletions app/src/main/res/layout/setup_fragment.xml
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,8 @@
style="@style/BaseRecyclerList"
android:layout_width="match_parent"
android:layout_height="0dp"
android:contentDescription="Setup cards"
tools:ignore="HardcodedText"
android:clipToPadding="false"
android:paddingVertical="4dp"
app:layout_constraintBottom_toBottomOf="parent"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,8 @@
android:layout_width="match_parent"
android:layout_height="match_parent"
android:clipToPadding="false"
android:contentDescription="SystemCleaner custom filters"
tools:ignore="HardcodedText"
android:paddingVertical="4dp"
android:paddingBottom="100dp"
app:layout_behavior="@string/appbar_scrolling_view_behavior"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,8 @@
android:paddingVertical="4dp"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toEndOf="parent"
android:contentDescription="SystemCleaner filter content"
tools:ignore="HardcodedText"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent"
tools:listitem="@layout/systemcleaner_filtercontent_element_header" />
Expand Down
2 changes: 2 additions & 0 deletions app/src/main/res/layout/systemcleaner_list_fragment.xml
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,8 @@
android:visibility="invisible"
tools:visibility="visible"
android:paddingVertical="4dp"
android:contentDescription="SystemCleaner results"
tools:ignore="HardcodedText"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@
android:id="@+id/list"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:contentDescription="Delete confirmation previews"
tools:ignore="HardcodedText"
android:layout_margin="16dp"
app:layoutManager="androidx.recyclerview.widget.GridLayoutManager"
app:layout_constraintEnd_toEndOf="parent"
Expand Down
4 changes: 3 additions & 1 deletion app/src/main/res/layout/view_preference_seekbar.xml
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,10 @@
android:id="@+id/slider"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:contentDescription="Slider for minimum app junk size"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@id/slider_value" />
app:layout_constraintTop_toBottomOf="@id/slider_value"
tools:ignore="HardcodedText" />
</androidx.constraintlayout.widget.ConstraintLayout>
1 change: 1 addition & 0 deletions app/src/main/res/values/styles.xml
Original file line number Diff line number Diff line change
Expand Up @@ -183,6 +183,7 @@
<style name="SDMToolbar.Primary" parent="Widget.MaterialComponents.Toolbar.Primary">
<item name="android:layout_height">wrap_content</item>
<item name="android:minHeight">?actionBarSize</item>
<item name="navigationContentDescription">Navigate back</item>
</style>

</resources>

0 comments on commit 09a1b74

Please sign in to comment.