-
Notifications
You must be signed in to change notification settings - Fork 29.8k
Closed
Labels
a: accessibilityAccessibility, e.g. VoiceOver or TalkBack. (aka a11y)Accessibility, e.g. VoiceOver or TalkBack. (aka a11y)f: material designflutter/packages/flutter/material repository.flutter/packages/flutter/material repository.found in release: 3.10Found to occur in 3.10Found to occur in 3.10found in release: 3.11Found to occur in 3.11Found to occur in 3.11frameworkflutter/packages/flutter repository. See also f: labels.flutter/packages/flutter repository. See also f: labels.has reproducible stepsThe issue has been confirmed reproducible and is ready to work onThe issue has been confirmed reproducible and is ready to work on
Description
Is there an existing issue for this?
- I have searched the existing issues
- I have read the guide to filing a bug
Steps to reproduce
- Run my sample, pasted below.
- Tap the button in the center a few times. It has two states: selected and unselected.
- Activate a screen reader (I used VoiceOver on iOS)
- Use the screen reader to cause the button to be "pressed". (With VoiceOver, I found this is done with a double-tap.)
- Notice that its tooltip ("hello") is read, but the selected/unselected state is not.
Expected results
I expected the selected/unselected state to be read aloud.
Actual results
The selected/unselected state was not read aloud.
Code sample
Code sample
import 'package:flutter/material.dart';
void main() {
runApp(const MyApp());
}
class MyApp extends StatelessWidget {
const MyApp({super.key});
@override
Widget build(BuildContext context) {
return MaterialApp(
theme: Theme.of(context).copyWith(useMaterial3: true),
home: const Scaffold(
body: Center(
child: Column(
mainAxisAlignment: MainAxisAlignment.center,
children: [
Text('Button:'),
MyButton(),
],
),
),
),
);
}
}
class MyButton extends StatefulWidget {
const MyButton({Key? key}) : super(key: key);
@override
State<MyButton> createState() => _MyButtonState();
}
class _MyButtonState extends State<MyButton> {
bool _selected = false;
@override
Widget build(BuildContext context) {
return IconButton(
onPressed: () {
setState(() {
_selected = !_selected;
});
},
tooltip: 'hello',
isSelected: _selected,
icon: const Icon(Icons.arrow_left),
selectedIcon: const Icon(Icons.arrow_right),
);
}
}Screenshots or Video
Screenshots / Video demonstration
N/A
Logs
Logs
No errors logged or expected.
Flutter Doctor output
Doctor output
$ flutter doctor -v
[✓] Flutter (Channel main, 3.11.0-6.0.pre.35, on macOS 13.3.1 22E772610a darwin-x64, locale en-US)
• Flutter version 3.11.0-6.0.pre.35 on channel main at /Users/chrisbobbe/.local/lib/flutter
• Upstream repository https://github.com/flutter/flutter.git
• Framework revision 37fe1e9d77 (7 days ago), 2023-05-11 12:43:40 -0400
• Engine revision f38f46f66e
• Dart version 3.1.0 (build 3.1.0-94.0.dev)
• DevTools version 2.23.1
[✓] Android toolchain - develop for Android devices (Android SDK version 30.0.3)
• Android SDK at /Users/chrisbobbe/Library/Android/sdk
• Platform android-33, build-tools 30.0.3
• ANDROID_HOME = /Users/chrisbobbe/Library/Android/sdk
• Java binary at: /Applications/Android Studio.app/Contents/jre/Contents/Home/bin/java
• Java version OpenJDK Runtime Environment (build 11.0.13+0-b1751.21-8125866)
• All Android licenses accepted.
[✓] Xcode - develop for iOS and macOS (Xcode 14.3)
• Xcode at /Applications/Xcode.app/Contents/Developer
• Build 14E222b
• CocoaPods version 1.11.3
[✓] Chrome - develop for the web
• Chrome at /Applications/Google Chrome.app/Contents/MacOS/Google Chrome
[✓] Android Studio (version 2021.3)
• Android Studio at /Applications/Android Studio.app/Contents
• Flutter plugin can be installed from:
🔨 https://plugins.jetbrains.com/plugin/9212-flutter
• Dart plugin can be installed from:
🔨 https://plugins.jetbrains.com/plugin/6351-dart
• Java version OpenJDK Runtime Environment (build 11.0.13+0-b1751.21-8125866)
[✓] VS Code (version 1.78.2)
• VS Code at /Applications/Visual Studio Code.app/Contents
• Flutter extension can be installed from:
🔨 https://marketplace.visualstudio.com/items?itemName=Dart-Code.flutter
[✓] Connected device (3 available)
• Chris’s iPhone (mobile) • 00008110-000924383632801E • ios • iOS 16.4.1 20E252
• macOS (desktop) • macos • darwin-x64 • macOS 13.3.1 22E772610a darwin-x64
• Chrome (web) • chrome • web-javascript • Google Chrome 113.0.5672.126
! Error: Chris’s Apple Watch needs to connect to determine its availability. Check the connection between the
device and its companion iPhone, and the connection between the iPhone and Xcode. Both devices may also need to
be restarted and unlocked. (code 1)
[✓] Network resources
• All expected network resources are available.
• No issues found!gnprice
Metadata
Metadata
Assignees
Labels
a: accessibilityAccessibility, e.g. VoiceOver or TalkBack. (aka a11y)Accessibility, e.g. VoiceOver or TalkBack. (aka a11y)f: material designflutter/packages/flutter/material repository.flutter/packages/flutter/material repository.found in release: 3.10Found to occur in 3.10Found to occur in 3.10found in release: 3.11Found to occur in 3.11Found to occur in 3.11frameworkflutter/packages/flutter repository. See also f: labels.flutter/packages/flutter repository. See also f: labels.has reproducible stepsThe issue has been confirmed reproducible and is ready to work onThe issue has been confirmed reproducible and is ready to work on