142 Commits

Author SHA1 Message Date
Michael Goderbauer
40a262b67c
Update outdated links (#23513) 2021-01-08 10:14:01 -08:00
Emmanuel Garcia
091b6cc5b4
Fix talkback in hybrid composition while using FlutterFragmentActivity (#22429) 2020-11-12 10:30:29 -08:00
chunhtai
9b4bb20ac9
makes android semanticsnode to ignore hittest if it is not focusable (#22205) 2020-11-02 09:53:01 -08:00
chunhtai
aed8e019be
Fixes Edge trigger route change announcement (#21975) 2020-10-22 14:22:03 -07:00
Emmanuel Garcia
9981026173
Allow TalkBack navigation while a platform view is rendered (#21719) 2020-10-13 17:52:02 -07:00
Dan Field
48687ca3ca
Forbid android.util.Log (#21696) 2020-10-08 14:52:05 -07:00
Jason Simmons
fc4da62b8c
Ignore calls to AccessibilityBridge listeners after release (#20701)
AccessibilityBridge installs various listeners for Android events
that invoke Flutter engine APIs.  These listeners are removed in
AccessibilityBridge.release.  However, in some environments there may
be deferred calls to the listener that will still execute even after
the listener has been removed.  This change sets a flag during release
and ignores any listener invocations that happen after the flag is set.

See https://github.com/flutter/flutter/issues/63555 and
https://github.com/flutter/engine/pull/17311
2020-08-27 12:24:33 -07:00
chunhtai
ccaee70b05
Missing default focus when navigating to a page with no SemanticsNode that sets namesRoute:true (#20516) 2020-08-19 14:06:03 -07:00
Jason Simmons
042804b06d
Disconnect the channel message handler when releasing the AccessibilityBridge (#18657) 2020-05-29 16:23:01 -07:00
Gary Qian
52a815df0a
Accessibility null check to catch out of bounds hitTest (#17833) 2020-04-21 06:16:42 -07:00
Michael Goderbauer
f4d6ce13dc
Clear focus if a platform view goes away (#17381) 2020-04-16 13:23:05 -07:00
Jonah Williams
6e1d7f8883
[a11y] Support TalkBack reading by word, character, and paragraph (#17626) 2020-04-15 19:07:12 -07:00
Emmanuel Garcia
025e2d82dd
Migrate embedding to AndroidX (#17075) 2020-03-13 21:19:24 -07:00
Michael Klimushyn
077918dcfd
Apply Google Java format (#16501)
This shouldn't result in any logical changes. I've done a quick smoke
test by building a local Android engine and running Flutter gallery, no
compile errors or other obvious issues.

Applied by running `/ci/format.sh | patch -p0` with the altered script
added in flutter/engine#16500. I did locally modify the script slightly
further so it would run against all Java files in the repo instead of
just modified ones.
2020-02-07 16:10:46 -08:00
Dan Field
e3e2a3899e
Remove suprious warning (#14079) 2019-12-02 16:51:30 -08:00
Dan Field
ea721ebf1a
Fix live region logic (#14081) 2019-12-02 15:49:15 -08:00
Darren Austin
3ea4005844
Added Semantic header support on Android. (#13262)
Added Semantic header support on Android.
2019-11-05 15:27:25 -08:00
Jonah Williams
6ab23d37d5
fix NPE in accessibility bridge (#13255) 2019-10-21 15:35:34 -07:00
Greg Spencer
21b8224ae1
Send AccessibilityEvent.TYPE_VIEW_FOCUSED when input focus is set. (#12746)
When the focus changes, we should be sending a TYPE_VIEW_FOCUSED event. This enables that.
2019-10-08 16:54:17 -07:00
Kate Lovett
58d7b84177
Re-land Adding Link Semantics (#12972) 2019-10-08 11:27:56 -07:00
Kate Lovett
ac45051f2a
Revert "Adding Link SemanticsFlag (#12453)" (#12815)
This reverts commit 974ca210f5275aee0775b363e9c3416e1603cf73.
2019-10-04 17:06:32 -07:00
Kate Lovett
974ca210f5
Adding Link SemanticsFlag (#12453) 2019-10-04 12:51:10 -07:00
Greg Spencer
e76089a451
Stop setting the accessibility text if a node has SCOPES_ROUTE set. (#12730)
This keeps us from setting the text on a node if it is a SCOPES_ROUTE node, and sends the "TYPE_VIEW_FOCUSED" event when we update the semantics information and a view has the input focus.
2019-10-02 10:35:28 -07:00
Greg Spencer
05f4b33cd2
Add isFocusable to SemanticsFlag (#12618)
This adds an isFocusable to SemanticsFlag so that the framework can tell the engine what semantics nodes are allowed to be focused, which will affect what platform flags are applied to the semantics information.

This flag is not yet in use by the frame
2019-09-30 09:46:48 -07:00
Greg Spencer
b3f2aad1c6
Revert "Send TYPE_VIEW_FOCUSED for views with input focus. (#12410)" (#12455)
This reverts commit c1773f3c57eb957fbc1702b8353b35648c38e372 because it breaks the Flutter framework build.
2019-09-25 20:35:55 -07:00
Greg Spencer
c1773f3c57
Send TYPE_VIEW_FOCUSED for views with input focus. (#12410)
This change modifies the accessibility bridge so that if a node has input focus, then it will tell TalkBack so that it will request the accessibility focus for the view.

It also sets the content change types bit field to include CONTENT_CHANGE_TYPE_SUBTREE to indicate that the subtree for the view has changed for API levels after, and including, KitKat (19)
2019-09-25 14:14:00 -07:00
Michael Goderbauer
ef7bcafd5c
a11y: expose max character count for text fields (#12269) 2019-09-16 09:37:25 -07:00
Michael Klimushyn
ed88d0a44d
Change SemanticsNode#children lists to be non-null (#10952)
Prevents NPEs and simplifies the code needed to handle these collections. There doesn't seem to have been a meaningful difference between null and empty collection here. The specific crash was happening when `object.scrollChildren > 0` while `object.childrenInHitTestOrder == null`, which looks like it may be a bug on its own and probably needs further investigation.
2019-08-12 17:16:59 -07:00
Mouad Debbar
8849d3092d
Add multi-line flag to semantics (#9850) 2019-07-17 09:51:09 -07:00
chunhtai
9ab6550b45
Introduce read only text field semantics (#9281) 2019-06-19 09:42:23 -07:00
Dan Field
069e38a0b9
Document AccessibilityBridge.java (#9237) 2019-06-07 16:00:38 -07:00
Dan Field
5d1c1a027e
Remove more asserts and fix a11y check (#8896) 2019-05-08 01:19:24 -07:00
Dan Field
5a045dd1f7
Log instead of throwing (#8881) 2019-05-07 11:08:38 -07:00
Dan Field
7ce2666e54
Guard Android logs (#8824) 2019-05-03 14:32:29 -07:00
Dan Field
480844608c
Remove asserts and add BuildConfig (#8821) 2019-05-02 17:30:19 -07:00
Amir Hardon
345ae7d373
Delegate a11y events and action to/from embedded Android platform views. (#8250)
Delegate a11y events and action to/from embedded Android platfrom views.

This handles delegation of:
  * AccessibilityNodeProvider#performAction
  * ViewGroup#requestSendAccessibilityEvent
  * View#onHoverEvent

Additionally updates the currently input accessibility focused node state that is
tracked by the a11y bridge when an embedded view's node is focused.
2019-03-25 14:26:49 -07:00
Amir Hardon
06635d38a9
Mirror Android platform views a11y tree in the Flutter a11y tree. (#8237)
This PR mirrors virtual a11y tree of embedded platform views in the Flutter
a11y tree.

Non virtual hierarchies are not currently supported.

Only works on Android versions earlier than Android P as it relies on
reflection access to hidden system APIs which cannot be done starting
Android P.

A11y is not yet working as we also need to delegate a11y events from the
platform view to the FlutterView. This will be done in a following PR to
keep the change size a little saner.
2019-03-21 15:26:44 -07:00
Matt Carroll
188adf7e5e
Removed Activity reference from AccessibilityBridge by using a View for insets instead of the Activity (#18115) (#8231) 2019-03-20 14:18:34 -07:00
Amir Hardon
6a8a45fc4f
Have the AccessibilityBridge attach/detach itself to the (#8229)
PlatformViewsDelegate.

Since onDetachedFromWindow can be called after the activity was
destroyed, the previous call to detach the accessibility bridge could
have crash as the NativeFlutterView was already null.
2019-03-20 12:26:30 -07:00
Amir Hardon
45f69ac471
Plumb a reference of PlatformViewsController and AccessibilityBridge to each other (#8208)
This is in preparation for implementing platform views a11y on Android.

And e2e working prototype is available here: https://github.com/amirh/engine/tree/a11y_hacks

flutter/flutter#19418
2019-03-19 15:48:45 -07:00
Matt Carroll
09db84fad6
Android Embedding PR 19: Add accessibility to new FlutterView. (#8109) 2019-03-14 14:24:49 -07:00
Michael Goderbauer
bd0f9085e5
Adds a platfromViewId to SemanticsNode (#8055) 2019-03-11 11:30:35 -07:00
Jonah Williams
4e54bc93ca
Guard initialization of touch exploration listener (#8103) 2019-03-09 15:07:26 -08:00
Matt Carroll
718329ce6e
Android Embedding PR 17: Clarify AccessibilityBridge and move logic out of FlutterView. (#8061) 2019-03-08 18:09:04 -08:00
Michael Klimushyn
1d10e0eb67
Guard against NewAPI failures (#8048)
Adds minimum SDK checks around minimum APIs.

flutter/flutter#28848
2019-03-08 13:33:58 -08:00
Matt Carroll
2f4a38dbd3
Android embedding refactor pr3 add remaining systemchannels (#7892)
Merging back in after reversion. Fixed some messaging issues in FlutterNativeView and corrected some message parsing.
2019-02-20 17:05:31 -08:00
Dan Field
6d7eb52185
Revert "Android embedding refactor pr3 add remaining systemchannels (#7874)" (#7886)
This reverts commit f4fba6d7110338caf3878cf42e26e17744108d00.
2019-02-20 11:18:12 -08:00
Matt Carroll
f4fba6d711
Android embedding refactor pr3 add remaining systemchannels (#7874) 2019-02-19 15:51:13 -08:00
Chris Bracken
163a2fd5e1
Revert "Android embedding refactor pr3 add remaining systemchannels (#7738)" (#7849)
From build log:
```
../../flutter/shell/platform/android/io/flutter/view/FlutterView.java:95: error: cannot find symbol
    private final LocalizationChannel localizationChannel;
                  ^
  symbol:   class LocalizationChannel
  location: class FlutterView
../../flutter/shell/platform/android/io/flutter/view/FlutterView.java:172: error: cannot find symbol
        localizationChannel = new LocalizationChannel(dartExecutor);
                                  ^
  symbol:   class LocalizationChannel
  location: class FlutterView
2 errors
```

This reverts commit 256db4bc23b7931509233df0dc04e44e16608229.
2019-02-15 15:03:19 -08:00
Matt Carroll
256db4bc23
Android embedding refactor pr3 add remaining systemchannels (#7738) 2019-02-15 13:45:24 -08:00