* Move dart:mojo.internal to //flutter/lib/mojo
To be parallel with the other built-in libraries.
* Move DartRuntimeHooks into //flutter/lib/ui
This code manipulates natives.dart, which is part of //flutter/lib/ui.
There are now three ways to start Dart applications:
1) From a precompiled snapshot
2) From a snapshot
3) From source
When loading from source, we no longer use the complex data pipe /
dependency catcher mechanism. Instead, we just load the source
synchronously from the file system. This is appropriate because running
from source is used only during development and not during production.
The previous design was built assuming we would want to run from source
over the network, which meant we needed to be able to load source
asynchronously over a high latency channel.
* Remove time
* Remove rand
* Remove array buffers
* Remove more code
* Remove more image decoding code
* Remove more code
* Remove old public API
* Remove more old public headers
* Remove layout test support
* Remove WebPrivateOwnPtr
* Remove WebString
* Remove worker pool
This patch:
- makes dart traces (coming from the VM and the timeline API)
available to mojo:tracing
- adds --vm-complete-timeline parameter, which makes the Dart VM enable all
categories of timeline traces from the beginning, allowing to do startup
tracing
This is based on the equivalent support in dart content handler.
Fixes https://github.com/flutter/flutter/issues/3162.
This include build system changes for selecting Dart's precompiler mode
plus a way to locate and load the precompiled snapshot library from an
Android application
Dart invokes Start/StopTracing callbacks within the _setVMTimelineFlags service
method whenever the embedder timeline stream toggles on or off. Flutter's
implementation of these callbacks was modifying the set of enabled streams,
which could override the intended behavior of _setVMTimelineFlags.
Start/StopTracing will now only control Flutter's embedder-specific log.
Also needed to change the Flutter engine's --trace-startup flag to set the
corresponding timeline stream flag on the Dart VM.
Now that we understand window insets, we don't need to hard-code the size of
the status bar. Also, convert the viewport metrics to be consistently in
physical pixels.
We used to share memory between Dart strings and WTF::String objects by
way of the Dart externalized strings. That used to be important when the
DOM shared many strings between C++ and Dart. However, now that we don't
retain strings in C++ much anymore, we don't need this complexity.
This patch removes DartStringCache and the integration. It also unwinds
several cases where we were converting back and forth between
WTF::String and std::string for no reason. Now we use std::string more
consistently.
For the case of ParagraphBuilder::addText, we now take a raw const
char*, which more closely matches the API the DartVM exposes. That means
we do a single copy out of the VM and into the render tree at that
point.
This complex machinery made sense for Blink, which has hundreds of
developers. In our case, we're just moving around two bools. We can do
that in a much simpler way.