438 Commits

Author SHA1 Message Date
Zachary Anderson
00607f96ea Reland: Roll clang and buildroot (flutter/engine#33339) 2022-05-14 06:04:14 -07:00
Jason Simmons
b36737f3ce Add an explicit null check to DartConverterWrappable::FromDart (flutter/engine#33188) 2022-05-06 19:59:04 -07:00
Chris Bracken
09285aac02 Use empty in place of size checks vs 0 (flutter/engine#33151) 2022-05-06 13:09:04 -07:00
Zachary Anderson
d85395558f Revert "dart:ui conversion from native to FfiNative" (flutter/engine#33116) 2022-05-04 16:24:06 -07:00
Clement Skau
ca1dc06bc1 dart:ui conversion from native to FfiNative (flutter/engine#29607) 2022-05-04 09:29:05 -07:00
Chris Bracken
0a84242538 WinUWP: Remove WinUWP sources, targets (flutter/engine#33019)
This removes:
* The Windows UWP emebedder sources and targets
* UWP-specific build targets
* UWP-specific code behind WINUWP #ifdefs
* UWP-specific TODOs.
* uwptool.exe sources and targets used for installing, uninstalling, and
  launching UWP apps.

This is a straight removal patch, and does not land any refactorings
made possible by removal of UWP support. Those patches will land in
followup refactorings.

Tool support was removed in:
https://github.com/flutter/flutter/pull/102174

The CI target was removed in:
https://github.com/flutter/engine/pull/33012

The Recipe was removed in:
https://flutter-review.googlesource.com/c/recipes/+/29500

GN build support was removed in:
https://github.com/flutter/engine/pull/33016

Issue: https://github.com/flutter/flutter/issues/102172
2022-04-29 18:39:36 -07:00
Jason Simmons
2cb5459327 Add a benchmark that measures SkParagraph ParagraphBuilder for a simple use case (flutter/engine#32985) 2022-04-28 13:08:11 -07:00
Chris Bracken
a970f9766a Minor unique_ptr initialization cleanup (flutter/engine#32821)
Cleans up a few cases of std::unique_ptr(new T) that could have been
using std::make_unique<T>(...).
2022-04-20 17:08:00 -07:00
Jason Simmons
c8aa503a12 Fix the CanvasPath::CreateNew signature to avoid unnecessary Dart API::NewError calls (flutter/engine#32791) 2022-04-20 07:24:04 -07:00
Dan Field
4101b52aca Unify unhandled error reporting, add PlatformDispatcher.onError (flutter/engine#32078) 2022-04-09 14:44:04 -07:00
Jason Simmons
4c53a23215 Web HTML support for variable fonts (flutter/engine#32327) 2022-03-30 13:45:01 -07:00
eggfly
740d276f3d Fix crash of Minikin global lock while exiting app (flutter/engine#32289) 2022-03-30 13:35:05 -07:00
Jason Simmons
c133cad506 Add an API for variable font axes in TextStyle and connect it to SkParagraph (flutter/engine#32245) 2022-03-28 13:35:02 -07:00
eggfly
f3efac3388 [windows] Support win_debug_x86 compilation target in engine (flutter/engine#30417) 2022-03-15 20:10:10 -07:00
Kevin Lubick
3f3a993abf Fix Skia includes (flutter/engine#31909) 2022-03-10 07:45:31 -08:00
Chris Bracken
495467648f [win32] Disable a11y UIA unit tests (flutter/engine#31452)
Chrome's implementation of UI Automation support was only
partially-complete at the time we forked //third_party/accessibility. We
don't use UIA in Flutter, but rely instead entirely on the MSAA
accessiblity implementation.

Disabling these tests for now, rather than deleting, since we'll need to
make a decision on whetheer to port the updates from the Chromium tree,
or write our own simpler UIA implementation.

Issue: https://github.com/flutter/flutter/issues/98427
Related issue: https://github.com/flutter/flutter/issues/94782
2022-02-14 12:07:45 -08:00
Chris Bracken
81c662ef3d Enable a11y unittests on Windows (flutter/engine#31387)
This enables accessibility unittests on Windows as part of our CI testing.

It also corrects two unit tests which were fixed by
https://github.com/flutter/engine/pull/29773, which fixed
https://github.com/flutter/flutter/issues/78460.

Finally it disables an AXFragmentRoot test that times out. We don't use
AXFragmentRoot in Flutter as it's only used with UI Automation APIs,
which Flutter does not use (we use MSAA).

Issue: https://github.com/flutter/flutter/issues/98225
2022-02-12 12:51:01 -08:00
Chris Bracken
d232131bf0 [a11y] Delegate UTF8ToUTF16 to FML (flutter/engine#31376)
Delegates string encoding conversions between UTF-8 and UTF-16 strings
in //third_party/accessibility/base to our existing implementations in
FML.

Issue: https://github.com/flutter/flutter/issues/98061
2022-02-10 13:25:10 -08:00
Clement Skau
c988119386 Adds Tonic templates for Dart FFI bindings. (flutter/engine#29405)
This change adds additional Tonic templates for automatically generating bindings for Dart FFI, as well as serialisation of the bindings.

- Adds parallel FfiDispather templates to the existing DartDispatcher used for (old) native bindings.
- Adds serialisation of the bindings to enable automatic conversion and verification.
- Extends existing DartConverters with conversions to and from the FFI transport types.
- Adds new test (ffi_native_unittest.cc) for the above.

This will allow us to replace the existing native functions in e.g. dart:ui with new Dart FFI native functions.
2022-02-08 08:57:55 +01:00
Jason Simmons
f55649a744 Invalidate the ParagraphSkia line metrics caches when redoing layout (flutter/engine#31138) 2022-02-01 09:50:02 -08:00
Jason Simmons
a237fa84cd libtxt: Initialize ParagraphTxt::final_line_count_ (flutter/engine#30892) 2022-01-20 10:35:09 -08:00
Chris Bracken
55400d29eb Fix missing shcore.dll error on Windows 7 (flutter/engine#30699) 2022-01-05 15:50:03 -08:00
Jason Simmons
de66470b44 Roll HarfBuzz to version 3.1.1 (flutter/engine#30354)
Also migrates to the HarfBuzz 3.x font subsetting API
(see https://github.com/flutter/engine/pull/29266)
2021-12-16 08:13:08 -08:00
Greg Spencer
6079aa5f81 Reland: Accessibility number formatting improvements for Windows (#29773) (flutter/engine#30301)
This reverts commit e7c6dea to re-land the previous change in #29773.
Chinmay realized that because we link the whole engine into one DLL on Windows, the export settings for the symbols don't affect this code: If we include a second copy of the double-conversion library, the duplicate symbols are all internal to the DLL. Consequently, we need to link to the copy in the Dart runtime, so this is the correct implementation. If the Dart team decides to change/remove the library in the future, we will need to add in our own copy at that time.

This adds some accessibility improvements for reading out numbers. Currently this code is only used on Windows.
2021-12-14 13:24:45 -08:00
Greg Spencer
e7c6deaef6 Revert "Accessibility number formatting improvements for Windows (#29773)" (flutter/engine#30267) 2021-12-10 13:09:10 -08:00
Greg Spencer
3911c3d5d8 Accessibility number formatting improvements for Windows (flutter/engine#29773)
This adds some accessibility improvements for reading out numbers. Currently this code is only used on Windows.

Fixes flutter#78460
2021-12-09 13:04:00 -08:00
Chris Bracken
93f6d81c75 Accessibility: emit FOCUS_CHANGED events (flutter/engine#30091)
When calling Unserialize on an AXTreeUpdate, check whether the focus_id
has changed. If so, emit a FOCUS_CHANGED event from the event generator.
This allows the platform-specific FlutterPlatformNodeDelegate
implementations to handle focus changes originating from the framework,
and trigger the appropriate operating system focus-changed
notifications.

Issue: https://github.com/flutter/flutter/issues/77838
2021-12-02 18:14:15 -08:00
Chris Bracken
679e34a3e3 Eliminate hardcoded scale factor in a11y scroll (flutter/engine#30013)
When performing an accessibilty scroll, the default scroll distance is
kSmallScrollIncrement (40 pixels). This value is then multiplied by the
system scale factor, as set in the display settings drop-down in the Windows
system settings.

When we imported the AX tree from Chromium, we hard-coded the system
scale factor to 1.0 due to a fair amount of abstraction of the scale
factor lookup in their code. This fills it back in.

Issue: https://github.com/flutter/flutter/issues/78798
2021-12-01 12:32:32 -08:00
Chris Bracken
f8dfe2fab4 Win32 a11y bridge and platform node delegates (flutter/engine#29829)
* Win32 a11y bridge and platform node delegates

This is the third in a series of patches adding accessibility support
for the Windows embedder. This patch wires in the Accessibility bridge,
and lands the core structure of the Windows FlutterPlatformNodeDelegate
and AccessibilityBridgeDelegate classes, including:

* Instantiating the AccessibilityBridge when the semantics tree is
  enabled.
* Creating FlutterPlatformNodeDelegate wrappers for semantics tree
  nodes.
* Handling custom action updates.
* Building and updating the accessibility tree on semantics updates.
* Returning the native IAccessible objects when queried.

Breaking this out so that the follow-up patches can be reviewed and
landed in smaller, independent chunks.

Issue: https://github.com/flutter/flutter/issues/77838
Issue: https://github.com/flutter/flutter/issues/93928
2021-11-29 13:23:42 -08:00
ColdPaleLight
9ecd4c1899 Make FlutterEngineGroup support dart entrypoint args (flutter/engine#29096) 2021-11-18 18:08:03 -08:00
Zachary Anderson
03c0f7e453 Add 'explicit' to header files (flutter/engine#29741) 2021-11-17 12:49:16 -08:00
George Wright
c859ffd744 Update third-party benchmark library (flutter/engine#29627)
* Roll benchmark to upstream github @ 431abd149fd76a072f821913c0340137cc755f36
Roll buildroot to bfa04ad85fed176aa909f880ef5c8009c945ba03 to get build files for benchmark

* Roll flutter_packages to b1fdbabbe70caa21566f6a815235d624c716ea16

* Add a task name to parse_and_send.dart's call to FlutterDestination.update()
2021-11-10 10:22:34 -08:00
Ahmed Ashour
acdc8a5c8b Fix typos (flutter/engine#29280) 2021-10-27 20:30:31 -07:00
Dan Field
f1dae7ad34 Delay default font manager to run concurrently with isolate setup (flutter/engine#29291)
* Delay default font manager to run concurrently with isolate setup

* test
2021-10-21 16:20:32 -07:00
Chris Bracken
8af486c93a Use accessibility_config for accessibility/ax (flutter/engine#29275)
//flutter/third_party/accessiblity/ax/ax_event_generator.cc includes the
AXEventGenerator::Iterator class which subclasses std::iterator, which
triggers an MSVC C++17 deprecation warning. This warning, can be
suppressed by defining _SILENCE_CXX17_ITERATOR_BASE_CLASS_DEPRECATION_WARNING
which is already done in the accessibility_config config.

Also updates the TODO to reference the issue tracking the cleanup and
removal of that definition.

Issue: https://github.com/flutter/flutter/issues/92229
2021-10-21 09:42:57 -07:00
Filip Filmar
5debecb677 Update the ICU library to 2b50fa94b07b601293d7c1f791e853bba8ffbb84 (flutter/engine#28646)
Originally I wanted to update to 3f443830bd52d3aa5fab3c1aa2b6d0848bb5039d.
However, that change had a problem with a misspelled build target which
I also had to fix.

But, that fix turned out to be infeasible on its own, and led to a
bugfix in `gn`.

Fixes:

- Updates gn to commit 0153d369bbccc908f4da4993b1ba82728055926a to take
  in the fix at https://gn-review.googlesource.com/c/gn/+/12220 which
  prevented the correct treatment of target refactoring.

- Updates ICU to commit 2b50fa94b07b601293d7c1f791e853bba8ffbb84 to
  correct the target naming, which should now work thanks to the
  previous update to gn.  See
  https://gn-review.googlesource.com/c/gn/+/12220 for the details of
  that bug.

- Fixed the visibility declaration in `//flutter/third_party/accessibility:accessibility_config`
  which used to not be enforced due to a bug in `gn` which was fixed in
  https://gn.googlesource.com/gn/+/46b572ce4ceedfe57f4f84051bd7da624c98bf01,
  a revision which we took in by updating `gn` in the first bullet.

Fun times.

See: https://chromium-review.googlesource.com/c/chromium/deps/icu/+/3163524

Please see the linked issue for details about why this update.
2021-09-24 12:27:21 -07:00
Darren Chan
b82554ae4a Implement a default font manager for Fuchsia. (flutter/engine#28673)
This helps us get rid of our hacky font switch after engine initialization.

See https://fxbug.dev/76406 and https://github.com/flutter/flutter/issues/82202.
2021-09-21 12:33:37 -07:00
Jason Simmons
d85d394682 Fix Libtxt unit test errors found by ASAN (flutter/engine#28146) 2021-08-17 15:27:01 -07:00
Chinmay Garde
dbc0d4d4b1 Ensure gclient sync is successful on an M1 Mac host. (flutter/engine#27354) 2021-07-13 15:26:02 -07:00
Martin Kustermann
91ff075a74 Make dart wrappable classes use only one native field (flutter/engine#27350)
* Make dart wrappable classes use only one native field

It appears like the second native field is never really used for
anything: It is set, cleared and verified it was cleared, but that is
it.

=> The only native field that is necessary is the `this` pointer of the
   equivalent C++ object.
=> The [DartWrapperInfo] object which was stored as second native field
   is always accessible via the virtual `GetDartWrapperInfo()` method on
   `this`.
2021-07-13 16:39:22 +02:00
Jason Simmons
663678b9de Use unstripped executables when running tests on Linux (flutter/engine#26921) 2021-06-29 07:31:02 -07:00
Jason Simmons
864165a64d Reserve space for the line metrics styles created by ParagraphSkia::GetLineMetrics (flutter/engine#26909) 2021-06-25 11:11:01 -07:00
chunhtai
d9a591eb9c Support text editing voiceover feedback in macOS (flutter/engine#25600) 2021-06-01 12:00:05 -07:00
Brandon DeRosier
a83c8ab61d Refactor: Group together externally-managed UIDartState. (flutter/engine#26247)
Group together externally-managed UIDartState.

It's a frequent pattern to enable access to shell resources from the
framework via UIDartState. These handles are passed through several
other objects, where they lay mostly dormant. This refactor just aims
to ease maintenance of this state.

UIDartState is essentially just an easy to extend bus for dropping
off the shell kids in UIDartState, with constructors/operators that
remove the need for providing a full initializer lists in unittests.
2021-05-20 18:01:53 -07:00
Brandon DeRosier
b9982cdec7 Add image generator registry (flutter/engine#25987)
Add image generator protocol and priority registry.

The protocol supports multi-frame images as well as optional
subpixel/downsampled decoding.
2021-05-17 12:12:46 -07:00
heke123
c59ffe8b9a Use "blur_sigma" instead of "blur_radius" in Shadow. (flutter/engine#25760) 2021-04-30 14:34:02 -07:00
Michael Reed
d05dafab40 Remove override; method no longer called (flutter/engine#25806)
* Remove override; method no longer called

* Remove override; method no longer called

Co-authored-by: Mike Reed <reed@google.com>
2021-04-28 08:18:19 -07:00
Jason Simmons
9c2c4dd009 Manual Skia roll to be1c99658979972e87cad02e9e5b979c190f2c99 (flutter/engine#25786) 2021-04-27 11:42:41 -07:00
LongCatIsLooong
fe01e1acbb [libTxt] resolve null leading distribution in dart:ui. (flutter/engine#25510) 2021-04-19 13:49:01 -07:00
Jason Simmons
662fdf023c Fix the kernel path in the DartPersistentHandleTest.ClearAfterShutdown test (flutter/engine#25585) 2021-04-14 08:36:29 -07:00