summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
author Treehugger Robot <android-test-infra-autosubmit@system.gserviceaccount.com> 2024-12-10 21:05:26 +0000
committer Android (Google) Code Review <android-gerrit@google.com> 2024-12-10 21:05:26 +0000
commitaabbec67c54c4489cec0f82fefd1acf8ff6f8b6c (patch)
tree4f7b88022c4864e78ea8affd52e5e7dd2d539ccb
parent023c47db32ee334041a66cc107154d5f7a863637 (diff)
parent53d3b64319802fd5ec060927d0f00e6122ae30f4 (diff)
Merge "Use appropriate types for a11y names" into main
-rw-r--r--packages/SystemUI/src/com/android/systemui/qs/tiles/ScreenRecordTile.java4
1 files changed, 3 insertions, 1 deletions
diff --git a/packages/SystemUI/src/com/android/systemui/qs/tiles/ScreenRecordTile.java b/packages/SystemUI/src/com/android/systemui/qs/tiles/ScreenRecordTile.java
index 4fb96e72d8df..ec8d30b01eab 100644
--- a/packages/SystemUI/src/com/android/systemui/qs/tiles/ScreenRecordTile.java
+++ b/packages/SystemUI/src/com/android/systemui/qs/tiles/ScreenRecordTile.java
@@ -24,6 +24,7 @@ import android.os.Looper;
import android.service.quicksettings.Tile;
import android.text.TextUtils;
import android.util.Log;
+import android.widget.Button;
import android.widget.Switch;
import androidx.annotation.Nullable;
@@ -144,8 +145,10 @@ public class ScreenRecordTile extends QSTileImpl<QSTile.BooleanState>
// Show expand icon when clicking will open a dialog
state.forceExpandIcon = state.state == Tile.STATE_INACTIVE;
+ state.expandedAccessibilityClassName = Button.class.getName();
if (isRecording) {
state.secondaryLabel = mContext.getString(R.string.quick_settings_screen_record_stop);
+ state.expandedAccessibilityClassName = Switch.class.getName();
} else if (isStarting) {
int countdown =
(int) ScreenRecordModel.Starting.Companion.toCountdownSeconds(
@@ -157,7 +160,6 @@ public class ScreenRecordTile extends QSTileImpl<QSTile.BooleanState>
state.contentDescription = TextUtils.isEmpty(state.secondaryLabel)
? state.label
: TextUtils.concat(state.label, ", ", state.secondaryLabel);
- state.expandedAccessibilityClassName = Switch.class.getName();
}
@Override