Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[iOS] Fix slider semantics node answer to accessibility activate #56427

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

bleroux
Copy link
Contributor

@bleroux bleroux commented Nov 7, 2024

Description

iOS fix [A11y] Double Tap brings the Slider thumb to the center of the widget. per instruction from flutter/flutter#157601 (comment)

I don't have a physical iOS device to double check, but using the iOS Simulator and accessibility tools, the behavior seems ok. Without this PR, the slider thumb goes to the center when clicking 'Activate', with this PR it does not :

Enregistrement.de.l.ecran.2024-11-07.a.11.09.01.mov

Related Issue

iOS fix for [A11y] Double Tap brings the Slider thumb to the center of the widget.

Tests

Adds 1 test.

@bleroux bleroux force-pushed the fix_ios_slider_semantics_node branch from a821ba0 to 5275592 Compare November 7, 2024 16:15
Copy link
Contributor

@chunhtai chunhtai left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, just need some comment

@@ -692,6 +692,9 @@ - (BOOL)accessibilityActivate {
return NO;
}
if (!self.node.HasAction(flutter::SemanticsAction::kTap)) {
if (self.node.HasFlag(flutter::SemanticsFlags::kIsSlider)) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you add a comment explain the reasoning?

@bleroux bleroux changed the title Fix slider semantics node answer to accessibility activate [iOS] Fix slider semantics node answer to accessibility activate Nov 8, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[A11y] Double Tap brings the Slider thumb to the center of the widget.
2 participants