mirror of
https://github.com/flutter/flutter.git
synced 2026-02-20 02:29:02 +08:00
TestAccessibilityBridgeDelegate::accessibility_events previously held values of type ui::AXEventGenerator::TargetedEvent. TargetedEvent contains an AXNode pointer and a const reference to a ui::AXEventGenerator::EventParams object, and as such it's unsafe to make or read copies of TargetedEvent values outside the scope of the AccessibilityBridgeDelegate::OnAccessibilityEvent callback. In this patch, we update the accessibility_events vector to simply hold EventType values since this is the only part of the value we use in our existing tests. If in future we need the full TargetedEvent, we'll need to properly copy these values. This patch also fixes a typo in the accessibility_events identifier and converts an EXPECT_EQ to an ASSERT_EQ in a case where the following test expectations are meaningless/could crash if the accessibility_events size isn't as expected. Issue: https://github.com/flutter/flutter/issues/77838
Description
Flutter makes it easy and fast to build beautiful apps for mobile and beyond
androidapp-frameworkcross-platformdartdart-platformdesktopflutterflutter-packagefuchsiaioslinux-desktopmacosmaterial-designmobilemobile-developmentskiawebweb-frameworkwindows
2.5 GiB
Languages
Dart
75%
C++
16.5%
Objective-C++
2.9%
Java
2.8%
Objective-C
0.7%
Other
1.9%