Skip to content

Commit 765284f

Browse files
XilaiZhanggspencergoog
authored andcommitted
[flutter roll] Revert both flutter#117338 and flutter#117547 (flutter#117557)
* Revert "Exposed tooltip longPress action when available (flutter#117338)" This reverts commit 38e3930. * Revert "fixes android_semantics_integration_test to expect long press for tootip"
1 parent edf1d58 commit 765284f

File tree

10 files changed

+3
-29
lines changed

10 files changed

+3
-29
lines changed

dev/integration_tests/android_semantics_testing/test_driver/main_test.dart

-1
Original file line numberDiff line numberDiff line change
@@ -439,7 +439,6 @@ void main() {
439439
ignoredActions: ignoredAccessibilityFocusActions,
440440
actions: <AndroidSemanticsAction>[
441441
AndroidSemanticsAction.click,
442-
AndroidSemanticsAction.longClick,
443442
],
444443
),
445444
);

packages/flutter/lib/src/material/tooltip.dart

+1-1
Original file line numberDiff line numberDiff line change
@@ -751,7 +751,7 @@ class TooltipState extends State<Tooltip> with SingleTickerProviderStateMixin {
751751
behavior: HitTestBehavior.opaque,
752752
onLongPress: (_triggerMode == TooltipTriggerMode.longPress) ? _handlePress : null,
753753
onTap: (_triggerMode == TooltipTriggerMode.tap) ? _handleTap : null,
754-
excludeFromSemantics: _excludeFromSemantics,
754+
excludeFromSemantics: true,
755755
child: result,
756756
);
757757
// Only check for hovering if there is a mouse connected.

packages/flutter/test/material/back_button_test.dart

-2
Original file line numberDiff line numberDiff line change
@@ -172,7 +172,6 @@ void main() {
172172
hasEnabledState: true,
173173
isEnabled: true,
174174
hasTapAction: true,
175-
hasLongPressAction: true,
176175
isFocusable: true,
177176
));
178177
handle.dispose();
@@ -217,7 +216,6 @@ void main() {
217216
hasEnabledState: true,
218217
isEnabled: true,
219218
hasTapAction: true,
220-
hasLongPressAction: true,
221219
isFocusable: true,
222220
));
223221
handle.dispose();

packages/flutter/test/material/calendar_date_picker_test.dart

-2
Original file line numberDiff line numberDiff line change
@@ -672,7 +672,6 @@ void main() {
672672
tooltip: 'Previous month',
673673
isButton: true,
674674
hasTapAction: true,
675-
hasLongPressAction: true,
676675
isEnabled: true,
677676
hasEnabledState: true,
678677
isFocusable: true,
@@ -681,7 +680,6 @@ void main() {
681680
tooltip: 'Next month',
682681
isButton: true,
683682
hasTapAction: true,
684-
hasLongPressAction: true,
685683
isEnabled: true,
686684
hasEnabledState: true,
687685
isFocusable: true,

packages/flutter/test/material/chip_test.dart

+1-4
Original file line numberDiff line numberDiff line change
@@ -2047,10 +2047,7 @@ void main() {
20472047
children: <TestSemantics>[
20482048
TestSemantics(
20492049
tooltip: 'Delete',
2050-
actions: <SemanticsAction>[
2051-
SemanticsAction.tap,
2052-
SemanticsAction.longPress
2053-
],
2050+
actions: <SemanticsAction>[SemanticsAction.tap],
20542051
textDirection: TextDirection.ltr,
20552052
flags: <SemanticsFlag>[
20562053
SemanticsFlag.isButton,

packages/flutter/test/material/date_picker_test.dart

-2
Original file line numberDiff line numberDiff line change
@@ -833,7 +833,6 @@ void main() {
833833
tooltip: 'Switch to input',
834834
isButton: true,
835835
hasTapAction: true,
836-
hasLongPressAction: true,
837836
isEnabled: true,
838837
hasEnabledState: true,
839838
isFocusable: true,
@@ -877,7 +876,6 @@ void main() {
877876
tooltip: 'Switch to calendar',
878877
isButton: true,
879878
hasTapAction: true,
880-
hasLongPressAction: true,
881879
isEnabled: true,
882880
hasEnabledState: true,
883881
isFocusable: true,

packages/flutter/test/material/floating_action_button_test.dart

-1
Original file line numberDiff line numberDiff line change
@@ -700,7 +700,6 @@ void main() {
700700
tooltip: 'Add Photo',
701701
actions: <SemanticsAction>[
702702
SemanticsAction.tap,
703-
SemanticsAction.longPress,
704703
],
705704
flags: <SemanticsFlag>[
706705
SemanticsFlag.hasEnabledState,

packages/flutter/test/material/search_test.dart

+1-4
Original file line numberDiff line numberDiff line change
@@ -620,10 +620,7 @@ void main() {
620620
SemanticsFlag.isEnabled,
621621
SemanticsFlag.isFocusable,
622622
],
623-
actions: <SemanticsAction>[
624-
SemanticsAction.tap,
625-
SemanticsAction.longPress,
626-
],
623+
actions: <SemanticsAction>[SemanticsAction.tap],
627624
tooltip: 'Back',
628625
textDirection: TextDirection.ltr,
629626
),

packages/flutter/test/material/tooltip_test.dart

-6
Original file line numberDiff line numberDiff line change
@@ -1420,9 +1420,6 @@ void main() {
14201420
id: 1,
14211421
tooltip: 'TIP',
14221422
textDirection: TextDirection.ltr,
1423-
actions: <SemanticsAction>[
1424-
SemanticsAction.longPress,
1425-
],
14261423
),
14271424
],
14281425
);
@@ -1623,9 +1620,6 @@ void main() {
16231620
tooltip: 'Foo',
16241621
label: 'Bar',
16251622
textDirection: TextDirection.ltr,
1626-
actions: <SemanticsAction>[
1627-
SemanticsAction.longPress,
1628-
],
16291623
),
16301624
],
16311625
),

packages/flutter/test/material/tooltip_theme_test.dart

-6
Original file line numberDiff line numberDiff line change
@@ -1075,9 +1075,6 @@ void main() {
10751075
tooltip: 'Foo',
10761076
label: 'Bar',
10771077
textDirection: TextDirection.ltr,
1078-
actions: <SemanticsAction>[
1079-
SemanticsAction.longPress,
1080-
],
10811078
),
10821079
],
10831080
),
@@ -1121,9 +1118,6 @@ void main() {
11211118
tooltip: 'Foo',
11221119
label: 'Bar',
11231120
textDirection: TextDirection.ltr,
1124-
actions: <SemanticsAction>[
1125-
SemanticsAction.longPress,
1126-
],
11271121
),
11281122
],
11291123
),

0 commit comments

Comments
 (0)