453 Commits

Author SHA1 Message Date
Zachary Anderson
c4fb8a6051 Revert "Adds semantics tooltip support (#27893)" (flutter/engine#28207)
This reverts commit 366e66802a35abf55bcb649b9bf58921b174b59a.
2021-08-19 14:40:34 -07:00
Zachary Anderson
e3f282c563 Revert "Add SPIR-V FragmentShader API to painting.dart (#26996)" (flutter/engine#28202)
This reverts commit 1b518619357cc1666a9fca183c9766d1ece16d0f.
2021-08-19 12:38:10 -07:00
chunhtai
366e66802a Adds semantics tooltip support (flutter/engine#27893) 2021-08-18 15:37:01 -07:00
Emircan Uysaler
69070156ab fuchsia: Add scaffolding and basic implementation for flatland migration (flutter/engine#27423)
* fuchsia: Add scaffolding for flatland migration

* fuchsia: Add ViewProvider based view creation logic and basic present loop
2021-08-18 13:23:32 -07:00
Anthony
1b51861935 Add SPIR-V FragmentShader API to painting.dart (flutter/engine#26996)
Add SPIR-V FragmentShader API to painting.dart
2021-08-18 12:58:25 -04:00
Kaushik Iska
2227552259 [fuchsia] [ffi] Basic support for Channels and Handles (flutter/engine#27849) 2021-08-16 12:57:01 -07:00
Kaushik Iska
1e9b7aed56 Build dart:zircon and dart:zircon_ffi (flutter/engine#28071) 2021-08-16 11:17:02 -07:00
Rich Kadel
51a5b01bad GN build rules for tests using Fuchsia SDK Dart libraries and bindings (flutter/engine#27996) 2021-08-13 08:52:01 -07:00
David Worsham
fb64905b15 Revert '[fuchsia] Make dart_runner work with cfv2' (flutter/engine#28036) 2021-08-12 09:22:22 -07:00
David Worsham
b00c549840 Fix thread names + add test (flutter/engine#27897) 2021-08-04 18:05:02 -07:00
Jonah Williams
2cc2854964 Add GestureSettings and configure touch slop from Android ViewConfiguration (flutter/engine#27836) 2021-08-03 12:55:02 -07:00
Chris Bracken
8803824c64 Migrate all Python hashbangs to Python 3 (flutter/engine#27838)
Migrates all `#!/usr/bin/env python` hashbang lines to use python3.

Also updates the licence tool to treat python3 scripts on par with
python 2 scripts.

Issue: https://github.com/flutter/flutter/issues/83043
2021-07-31 11:09:12 -07:00
Kaushik Iska
6ac3632741 [fuchsia] Fix DynamicLibrary.open path on Fuchsia (flutter/engine#27819) 2021-07-30 11:19:18 -07:00
Jaeheon Yi
0821f23495 [ui] Coerce DOWN pointer to inside the view. (flutter/engine#27632)
Floating point error can cause edge pointer coordinates to fall
slightly outside of the view's logical bounding box, causing a failure
of gesture recognition in Dart code. This patch coerces the DOWN pointer
to inside the logical view boundary.

https://github.com/flutter/flutter/issues/86882
2021-07-22 14:15:38 -07:00
freiling
6ad8eb6ec7 [fuchsia] boot lockup debugging improvements (flutter/engine#27459) 2021-07-22 13:06:01 -07:00
Tamir Duberstein
1481993626 Add fuchsia.net.name.Lookup (flutter/engine#27595)
fuchsia.net.NameLookup is transitioning to fuchsia.net.name.Lookup.
2021-07-20 22:57:07 -07:00
Tamir Duberstein
8739c597bf Reformat manifests (flutter/engine#27603)
cmx: $FUCHSIA_DIR/scripts/style/json-fmt.py
cml: $FUCHSIA_DIR/out/default/host-tools/formatjson5 --replace
2021-07-20 16:19:36 -07:00
David Worsham
934eced2e4 fuchsia: Add hermetic SessionConnection tests; rename (flutter/engine#27327) 2021-07-20 13:52:09 -07:00
Alexander Brusher
014a087925 Accounts for inverse pixel ratio transform in screen rects. (flutter/engine#27427) 2021-07-20 13:09:42 -07:00
Hunter Freyer
0e844e9ff4 Replace array<fml::Thread, 3> with ThreadHost. (flutter/engine#27455)
This is follow-up clean-up for #26193

Co-authored-by: Hunter Freyer <hjfreyer@google.com>
2021-07-20 12:46:10 -07:00
Darren Chan
cbcbbf7102 Migrate non-scenic-based fuchsia tests to cfv2. (flutter/engine#27241)
This PR also wraps up the soft transition for #27417.

Because some unit tests depend on the real Scenic which isn't hermetic, `flutter_runner_tests` and `flutter_runner_scenic_tests` aren't currently compatible with cfv2.
This will change once a FakeScenic is created (https://fxbug.dev/79873).

See https://fxbug.dev/79691.
2021-07-16 23:41:41 -04:00
Darren Chan
fe39238f25 Delete legacy focus platform message request handlers. (flutter/engine#27057)
Delete the following platform message request handlers:
 - `HostView.getCurrentFocusState`
 - `HostView.getNextFocusState`
 - `View.requestFocus`

See https://fxbug.dev/79740.
2021-07-15 16:24:36 -04:00
David Worsham
d707f91336 fuchsia: Log vsync stats in inspect (flutter/engine#27433) 2021-07-15 10:44:18 -07:00
Jason Simmons
219e22b0e2 Update the Fuchsia runner to use fpromise instead of fit::promise (flutter/engine#27416) 2021-07-14 19:31:06 -07:00
Felipe Archondo
573fe3dd0b [fuchsia] fix race in DefaultSessionConnection (flutter/engine#27377)
DefaultSessionConnection can run on two threads - the UI and raster
threads. This change ensures that all variables they both touch is
guarded by the mutex.

Fixes: fxbug.dev/80625
2021-07-14 22:10:15 -04:00
Kaushik Iska
45cf4e9ab1 [fuchsia] Use FFI to get System clockMonotonic (flutter/engine#27353) 2021-07-14 11:01:58 -07:00
Jason Simmons
6d0433831e Do not use the centralized graphics context options for Fuchsia Vulkan contexts (flutter/engine#27347) 2021-07-13 07:41: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
Kaushik Iska
12750e2e95 [fuchsia] Cleanup unused method in dart:zircon handle (flutter/engine#27330) 2021-07-12 11:40:42 -07:00
Chase Latta
d7a4148d62 [fuchsia] make dart_runner work with cfv2 (flutter/engine#27226)
Adds support for running the dart runner as a CFv2 component.
The runner has been refactored to launch in both a v1 environemnt
as well as a v2 environment.
2021-07-08 15:19:21 -07:00
David Worsham
32cded5dcd fuchsia: Handle clips on platform views (flutter/engine#27149) 2021-07-06 13:00:05 -07:00
Hunter Freyer
34b8a2b930 Replace flutter_runner::Thread with fml::Thread (flutter/engine#26783)
* Move task_observers.{cc,h} into fml.

This is a preparatory CL. The next CL will cause task_observers.h to
be included from both shell/platform/fuchsia _and_
fml/platform/fuchsia. I imagine it might be gauche for a single file
to be used from both those directories, but it seems way worse for fml
to depend on shell, rather than the other way around.

* Replace flutter_runner::Thread with fml::Thread.

This CL makes the treading logic in Fuchsia's flutter_runner more
consistent with fml expectations, but it still has quirks. Notably:

- Not all async work get posted to a fml::TaskRunner. Some work done
  by Fuchsia libraries gets posted directly to
  async_get_default_dispatcher(). This work doesn't trigger the
  fml::MessageLoop's task observers. As a result, we continue to have
  Fuchsia-specific task observers which fire for all async work,
  regardless of which way it was posted.

- There's awkwardness when trying to run Fuchsia code on a specific
  fml::TaskRunner if that fuchsia code accepts an
  async_dispatcher_t. Since you can no longer get an
  async_dispatcher_t for a given thread, you instead must post a
  closure to the fml::TaskRunner that calls
  async_get_default_dispatcher(), and then calls the fuchsia library
  with the default dispatcher.

- Some tests still use task_runner_adapter.h because async::Loop
  offers more control in unit tests than fml::MessageLoop does.

- If this successfully lands, there will be some cosmetic follow-up
  changes to make, like using ThreadHost instead of an array of
  fml::Threads.

* Increase stack size in flutter runner.

The previous change removes our custom 1MiB limit on the stack of
newly created threads, so these threads revert to the Fuchsia
default. google-internal tests were failing (without any particular
error in the logs) after this change, so here we just set the default
stack size to 1MiB.

Co-authored-by: Hunter Freyer <hjfreyer@google.com>
2021-07-06 10:04:08 -07:00
Darren Chan
cc3f93e26d Prepare for cfv2 unittests. (flutter/engine#27036) 2021-07-01 13:11:01 -07:00
Dan Field
72d7ac4ba4 Remove unnecessary experiment flag (flutter/engine#27072)
* Remove unnecessary experiment flag

* add explicit --no-sound-null-safety
2021-07-01 12:27:42 -07:00
David Worsham
5e5fe01dd2 Reland "fuchsia: Delete all the legacy code! (#26422)" (flutter/engine#27075)
This reverts commit bb3c49a9c3edf931a5601f0245faa85f5e077cb4.
2021-06-30 15:43:21 -07:00
Darren Chan
19e8b949e4 Fix use-after-free. (flutter/engine#27053)
Switch from `fml::NonOwnedMapping` to `fml::DataMapping`.

All other uses of `fml::NonOwnedMapping` are not in `PlatformView` and do not access data after references are out of scope.

This fixes https://fxbug.dev/77924.
2021-06-29 19:42:52 -04:00
Darren Chan
9e3b487842 [refactor] Migrate to View.focus.*. (flutter/engine#27005) 2021-06-29 09:41:01 -07:00
Darren Chan
a554250813 Always complete platform message requests. (flutter/engine#26994)
Functions/methods registered in `platform_message_handlers_` should return true or false, indicating whether the response was handled by them.
This makes it more explicit whether a platform message handler will asynchronously complete a response, versus if there was malformed/invalid request.

If the response was not handled, `CompleteEmpty` in `PlatformView::HandlePlatformMessage` to avoid hanging `Future`s in dart.

This fixes https://fxbug.dev/79056.
2021-06-29 09:58:31 -04:00
Chinmay Garde
7cfb375a5e Configure contexts to reduce shader variations. (flutter/engine#27016)
Context creation options for each backend were spread across multiple
translation units. This makes setting options common across all backends hard to
configure. I have moved the creation of such common options into a separate
translation unit.

Fixes https://github.com/flutter/flutter/issues/84213
2021-06-28 15:37:14 -07:00
Chase Latta
38cc5181d8 Allow fuchsia_archive to accept a cml file and cmx file (flutter/engine#27012)
This adds support for adding a cml file to a fuchsia package. The
cml file will be compiled to a cm file and included in the archive.
2021-06-28 13:48:21 -07:00
Dan Field
844fa85973 Fix Fuchsia build on Mac (flutter/engine#27007) 2021-06-28 10:36:01 -07:00
Darren Chan
7a203330e1 Emit viewRefFocused events in the flutter runner. (flutter/engine#26791)
Fulfill HostView.getCurrentFocusState and HostView.getNextFocusState platform message requests to deliver focus-related events to dart code.

Consolidate focus functionality (including requestFocus handling) to a new "FocusDelegate" class.

See https://cs.opensource.google/fuchsia/fuchsia/+/main:sdk/fidl/fuchsia.ui.views/view_ref_focused.fidl for details about focus state transitions and their meanings.

See https://fxbug.dev/77481.
2021-06-24 14:48:10 -04:00
Martin Kustermann
fde57f1f1d Remove usages of --no-causal-async-stacks (flutter/engine#26877)
Passing the --causal-async-stacks flag to the VM will cause it to error
on VM startup. The VM will remove the flag entirely, but before doing so
we'll have to remove usages of the negated version of the flag, namely
--no-causal-async-stacks.
2021-06-23 14:30:26 +02:00
Adlai Holler
3aaa10d762 Disable Skia reduceOpsTaskSplitting option (flutter/engine#26568)
This option will be the default in Skia soon. Per discussion in #26067, let’s be explicit about disabling it for the time being, and we can revisit the flag in the future if desirable.
2021-06-17 13:11:40 -07:00
Ren You
7d14b58d2d Revert "Replace flutter_runner::Thread with fml::Thread. (#26193)" (flutter/engine#26717) 2021-06-11 15:09:02 -07:00
David Worsham
bad9b71a01 Revert "fuchsia: Delete all the legacy code! (#26422)" (flutter/engine#26637)
This reverts commit 9afd7d6af8a0d023c0db67d24c55eb6c08c48aba.
2021-06-08 12:47:44 -07:00
David Worsham
9afd7d6af8 fuchsia: Delete all the legacy code! (flutter/engine#26422) 2021-06-07 17:29:39 -07:00
David Worsham
90b1f10ab7 fuchsia: Delete unused compilation_trace code (flutter/engine#20535) 2021-06-03 15:44:01 -07:00
Hunter Freyer
84d62201b6 Replace flutter_runner::Thread with fml::Thread. (flutter/engine#26193) 2021-06-03 14:39:04 -07:00
Darren Chan
f41e276f91 Migrate flutter_runner to Scenic.CreateSessionT. (flutter/engine#26536) 2021-06-03 08:49:02 -07:00