From 4b28bb694bbc005704102ae6e71ead053636dd21 Mon Sep 17 00:00:00 2001 From: "google-labs-jules[bot]" <161369871+google-labs-jules[bot]@users.noreply.github.com> Date: Wed, 13 May 2026 23:53:32 +0000 Subject: [PATCH] Add tooltips to icon-only buttons for accessibility Added `android:tooltipText` matching `android:contentDescription` to icon-only buttons (`help` in `sheet_photo_viewer_info.xml`, `sheet_alt_text.xml`, `alert_title_with_help.xml` and `severity` in `item_server_block.xml`). This provides hover and long-press tooltips on API 26+ devices, improving accessibility for mouse, stylus, and touch users without screen readers. Co-authored-by: dlukt <201112286+dlukt@users.noreply.github.com> --- mastodon/src/main/res/layout/alert_title_with_help.xml | 1 + mastodon/src/main/res/layout/item_server_block.xml | 1 + mastodon/src/main/res/layout/sheet_alt_text.xml | 1 + mastodon/src/main/res/layout/sheet_photo_viewer_info.xml | 1 + 4 files changed, 4 insertions(+) diff --git a/mastodon/src/main/res/layout/alert_title_with_help.xml b/mastodon/src/main/res/layout/alert_title_with_help.xml index fec7ec04f..8912e8980 100644 --- a/mastodon/src/main/res/layout/alert_title_with_help.xml +++ b/mastodon/src/main/res/layout/alert_title_with_help.xml @@ -16,6 +16,7 @@ android:tint="@color/selectable_icon_tint" android:background="@drawable/bg_round_ripple" android:contentDescription="@string/help" + android:tooltipText="@string/help" android:src="@drawable/ic_fluent_question_circle_24_selector"/> diff --git a/mastodon/src/main/res/layout/sheet_photo_viewer_info.xml b/mastodon/src/main/res/layout/sheet_photo_viewer_info.xml index f9f3b2c98..0d74b2e6e 100644 --- a/mastodon/src/main/res/layout/sheet_photo_viewer_info.xml +++ b/mastodon/src/main/res/layout/sheet_photo_viewer_info.xml @@ -130,6 +130,7 @@ android:background="?android:actionBarItemBackground" android:tint="?colorM3OnSurfaceVariant" android:contentDescription="@string/help" + android:tooltipText="@string/help" android:src="@drawable/ic_help_24px"/>