439 Commits

Author SHA1 Message Date
Chris Bracken
1340970bab
Assert in place of ArgumentError for null checks (#5612)
For consistency with the rest of dart:ui, check required parameters with
assert(param != null) rather than throwing ArgumentError. ArgumentError
is typically reserved for checking the validity of non-null args -- e.g.
that a list has the required number of elements.
2018-06-25 16:33:33 -07:00
Jason Simmons
e18f239037
Purge the Skia font cache after deleting an engine's FontCollection (#5598)
See https://github.com/flutter/flutter/issues/18728
2018-06-25 13:23:46 -07:00
Taryn
49838532d8 Fix Colors.fromARGB docs to mention the fromRGBO constructor (#5604) 2018-06-24 14:18:22 -07:00
bungeman
f9998a07bd Change ports/SkFontMgr.h to core/SkFontMgr.h (#5593)
Skia is moving ports/SkFontMgr.h to core/SkFontMgr.h. The existing
ports/SkFontMgr.h is now just a forwarding header to keep users working
through the transition. Update includes to point to the new location.
2018-06-22 11:04:58 -04:00
Jason Simmons
74ea64e912
Add a rowBytes parameter to decodeImageFromPixels (#5573)
See https://github.com/flutter/flutter/issues/9184
2018-06-21 18:05:54 -07:00
Ryan Macnak
fe9dd64d70
Replace AssetResolver GetAsBuffer with GetAsMapping. (#5546)
Toward no-copy loading of kernel.
2018-06-19 14:24:19 -07:00
Chinmay Garde
a7fda2b48c
Use SkImageFilter::MakeMatrixFilter instead of importing an internal Skia header. (#5569)
Part of fixing https://bugs.chromium.org/p/skia/issues/detail?id=7741
2018-06-19 13:26:06 -07:00
Alexander Aprelev
549c855e89
Roll dart sdk to 4c9689c1d2da97d0aa25cf16cc90c2e463ad157f (#5559)
* Roll dart sdk to 4c9689c1d2da97d0aa25cf16cc90c2e463ad157f

Changes since last roll:
```
4c9689c1d2 [vm] Support pluggable expression compiler for `evaluate` service api call.
d70c38eed8 [Gardening] Mark test as flaky on also non-kernel (legacy)
060ee6769e Make CastStreamSubscription.onData handle a null callback
f7289aa219 Remove specification of naming conventions.
87131780cb Add appendix to spec which specifies JavaScript integer behavior.
dfeaf79cef Fix VM accepting too many overlarge hex numbers in int.parse.
c84a9f46b2 Recompute ClassHierarchy after adding noSuchMethod forwarding stubs
b558a9c2f4 Handle missing compile-time errors
3df126c497 [gardening] Update status for vm-kernel-linux-debug
e22706793d Treat objects with .call as "subtypes" of function types
b960e5a3ed [gardening] Mark standalone_2/io/directory_test as Crash on dartkp/debug
e2d72aad91 Prepare tools/bots/try_benchmarks.sh for Dart 2.
de5f9ea95f Add --use-fasta-parser flags to dartanalyzer and the analysis server.
e2d903c4dc Remove packages/ directory resolution from CFE
aabb78f56a Update checked-in SDK to 2.0.0-dev.63.0 on mac and linux.
bc8d77231d Improve flags documentation, reenable hints in dart2js.
209a602769 Tweak for fixes tests - use orElse to avoid exception.
0e4c158847 Issue 33458. Suggest 'Create Class' Quick Fix for creation without new.
44650cc9eb Pass the location of vm_platform to compile_platform from the commandline.
0bac650833 switch to dart_action until prebuilt Windows Dart VM is updated
82ed18cdb9 Update checked-in Windows SDK to 2.0.0-dev.63.0
2394097e44 Support for including/excluding the same path in ContextRoot.isAnalyzed().
f59389b688 Optimize .runtimeType impact based on usage
ee1f7f5a93 Fix newly reported warnings
afa8ff6292 Add a resource provider that supports file overlays
a63cf8e0cb Add --no-preview-dart-2 flag.
2a396d5315 [vm/intrinsics] Intrinsify 64-bit int typed data.
dd8988c9b2 - Moved all WebGL rendering/drawing constants to synthesized class WebGL. - Removed obsolete Dartium/_blink code.
541dd195bb Enable creating full kernel files in addition to outlines from the bazel worker for kernel.
8e9e8e1da0 Fix various bugs and regularize behavior of returns statements in various kinds of functions.
f1d1da6164 [vm/precomp] Reduce the size of slow-path code in precompiled mode.
b51d3d4146 Key string should be avoided
1e906c3f7e Add no-op entry point for IncrementalCompiler
aeeb7baa96 Change error message to not use imperative tone
309baedc72 Mark some frequently flaky co19 dart2js tests.
1a08341730 Analyzer status file update
ac039abc83 Add option to check if a dill is self-contained
f479435bca - Removed custom handling of fill - it was wrong the method is now overloaded. - Associate the JS class SpeechSyntesisVoice with the correct Dart class (DDC). - Top-level querySelectorAll wasn't generic. - Handle "static" for attributes in the IDLs.
d2a37231b3 optimize await in async* methods in dartdevc
8f0106e490 Update more Analyzer fasta tests
53c2a6f9d5 Cleanup remaining unescape string call sites
1ef4399df0 Run dartfmt --fix for dart2 on pkg/dev_compiler
38eda19be6 Fix resolve_input_uri_test on windows.
5bf6436bc9 Initial implementations of two generators
03bcc495f7 [fuchsia] Migrate process creation to fdio_spawn_vmo
0cf860f361 Remove pub_build_validity test
c015e8d303 Improve invalid string literal error recovery
84f077842b Update CHANGELOG.md for 2.0.0-dev.63 release
7757fa784a [vm] Remove redundant Profiler::DumpStackTrace().
2bc9025be3 Consider initializing formals during top-level type inference
9df6426adb Mark the library analyzer.dart as being deprecated
bd956620fe Remove code that is causing a couple of hints
d99aeb3e13 [kernel] Update Fuchsia suspend to use new API.
6f44d3f208 Issue 2287. Move all, but constructors and fields set in constructors, from StatelessWidget into State.
729e9942bd Support multiple files in messages test.
99575f79ca Split ContextAwareGenerator and its subclasses
41a8b79475 Use the inferred type of const lists/maps to for constant evaluation.
2972ca61f8 Fix continue in invalidation logic
c54a302495 [VM] Evaluate symbols in kernel2kernel constant evaluator in AOT (even in non-const contexts)
4a7ccd5c9a Deleted TODO comment in Scoping
8dca855de1 Specify dynamic type of Futures/... returned from async/... functions
385d825469 Make frontend_server initialize from dill work again
2716b6f9a6 Add test to frontend_server that mimics the flutter benchmarks
17d2839a03 Fixed tests for FF difference.
6779ea0cc6 GN rules: add libraries_specification_uri argument to the  compile_platform template.
12b33ada44 [VM interpreter] Support NativeCall kernel bytecode.
db72134f90 [vm/inliner] Add smi return type of clamped convertors.
33feee3b03 [vm/kernel/bytecode] Fix arguments passing in native factory constructors
c30ce41ae6 Add hook to use single-root in fasta scripts and make use of it when creating the dart2js platform files.
34ee27a52d Update to the latest pub
bfb9a4eab8 linter 0.1.53
dfe6385eb0 Fix a Dart 2 runtime cast failure
f7ef66f5b0 Issue 33412. Fix for race condition in knownFiles during search.
aca417a256 Fix test and expected failure.
664f756914 [vm] Reduce maximum new generation size and growth rate.
bd603ba3c6 Record dependencies via CompilerContext
```
2018-06-18 20:56:50 -07:00
Jason Simmons
28e9e0f268
Create images from uncompressed pixel data (#5550)
Fixes https://github.com/flutter/flutter/issues/9184
2018-06-18 11:37:47 -07:00
Andrew Wilson
525dc18891
Make window metrics doubles to reduce rounding issues. (#5556) 2018-06-18 10:36:58 -07:00
Andrew Wilson
f5f57536d0 Revert "Make window metrics doubles to reduce rounding issues."
This reverts commit 15b76dd33c9844cb8a8de169f945ec1663c6f3ea.
2018-06-18 09:47:37 -07:00
Andrew Wilson
15b76dd33c Make window metrics doubles to reduce rounding issues. 2018-06-18 09:43:30 -07:00
Chinmay Garde
93c47a14ff
On snapshot, perform a device to host transfer for images resident on the GPU. (#5538) 2018-06-14 18:04:13 -07:00
Jason Simmons
c3c40cf958
Lazily load fonts that are embedded within the application (#5533)
Previously the engine would load all embedded fonts listed in the app's
font manifest during startup.  This change creates a Skia font manager that
is backed by the engine's AssetManager and can load embedded font assets
on demand.
2018-06-14 16:13:56 -07:00
Jason Simmons
efd6663344
Maintain a FontCollection for each engine instance instead of a process-wide singleton (#5521) 2018-06-13 14:28:21 -07:00
Ben Konyi
8d8d91bfc3
IsolateNameServer reland (#5519)
* Reland "Added IsolateNameServer functionality (#5410)"

This reverts commit c3976b3c7183f479717bffed3f640fb92afbd3dc.

* Fixed issue with isolate_name_server_test which caused test to timeout

* Disabled thread_annotations on Android as they aren't supported in the
NDK headers for std::mutex. Readded thread annotations to
IsolateNameServer.
2018-06-13 11:57:10 -07:00
Ben Konyi
c3976b3c71
Revert "Added IsolateNameServer functionality (#5410)" (#5516)
This reverts commit 61a2d129cfc8c52cf1ff59b03bccf67d9b07af63.
2018-06-12 17:03:13 -07:00
Ben Konyi
61a2d129cf
Added IsolateNameServer functionality (#5410)
* Added IsolateNameServer functionality, which allows for the association
of string names with isolate SendPort ids that can be used to establish
inter-isolate communications.
2018-06-12 15:50:48 -07:00
Dan Field
3b1f381cc5
Expose approximateBytesUsed for Picture (#5378) 2018-06-12 15:34:23 -04:00
Dan Field
d33bbff470
make analyzer happy (#5499) 2018-06-10 12:47:14 -04:00
Dan Field
8f023c5dac
Allow custom foreground paint to be used for drawing text (#5395)
* Allow specifying the foreground paint

* fix typo

* doc update

* call paint.reset
2018-06-10 00:21:18 -04:00
Stanislav Baranov
d4f5ef65a2
Support for saving Dart compilation trace on device. (#5443)
Support for saving Dart compilation trace on device.
2018-06-08 15:26:29 -07:00
Greg Spencer
5d2f24aa5c
Fixing image encoding format conversion. (#5489)
On a Linux host, we were having to convert the type of the bitmap to N32, but we weren't also fixing the channel order to RGBA, so consequently we were getting BGRA when the API was asking for RGBA. This forces the color format to be RGBA when that is what is asked for.

We weren't needing to do conversion on macOS, so macOS was always getting RGBA.
2018-06-07 18:06:47 -07:00
Greg Spencer
fca976d8c7
Fix animation diagram identifiers (#5481)
I forgot that the identifiers need to be unique per page for the animation tags.
This makes them unique.

Doc change only, no code.
2018-06-06 16:15:13 -07:00
Greg Spencer
7ec4b6115d
Add diagram links for StrokeJoin and StrokeCap (#5456)
This updates the documentation for StrokeJoin and StrokeCap to contain animated diagrams that describe their function. The actual diagrams reside in the assets-for-api-docs repo.
2018-06-06 14:10:52 -07:00
Alexander Aprelev
a83b37d35a
Roll dart to a5e41681e55d1e74684bfff530218db556d77ee8 (#5467)
* Roll dart to a5e41681e55d1e74684bfff530218db556d77ee8.

* Update license
2018-06-05 08:35:44 -07:00
Greg Spencer
6bfd413bee
Synchronizes analysis_options.yaml files, and turns on Function typedef lint. (#5419)
Addresses flutter/flutter#18028 for the engine repo, and synchronizes the analysis_options.yaml files between the engine and the flutter/flutter repo.
2018-05-30 16:06:05 -07:00
Michael Goderbauer
8a69d7f7ac
Add toString to WindowPadding (#5375) 2018-05-29 14:16:17 -07:00
Yegor
3d213f5548
remove the no longer used children parameter (#5333) 2018-05-22 12:44:42 -07:00
Todd Volkert
dee0a224ac
Support single-argument signature in Canvas.scale() (#5334) 2018-05-22 12:10:38 -07:00
Yegor
f876bd5710
split children into two ordered lists: traversal and hit test (#5091)
* split `children` into two ordered lists: traversal and hit test

* address comments

* reduce node object byte size

* link to DebugSemanticsDumpOrder
2018-05-21 17:44:23 -07:00
liyuqian
eacf06793c
Add debug asserts to using SkVertices::Builder (#5292)
Fixes flutter/flutter#9226
2018-05-18 10:32:56 -07:00
Greg Spencer
05a1687cf6
Moving assets-for-api-docs links to point to new asset dir. (#5296)
No logic changes, only links in doc comments.
2018-05-18 08:56:34 -07:00
Dan Field
0a74ef48f2
TwoPointConicGradients again (#5299)
* update docs for getBounds

* Add computeMetrics suggestion

* better explanation

* Support for TwoPointConical gradients
2018-05-18 07:43:52 -04:00
Alexander Aprelev
4a7940075c
Revert "Support for TwoPointConical gradients (#5275)" (#5293)
This reverts commit 919e8c211f518f17dbd298d9f8e39091b9e3897f as it
breaks flutter gradient_test.
2018-05-17 14:10:19 -07:00
Dan Field
ef0915c106
update docs for Path.getBounds (#5261)
* update docs for getBounds

* Add computeMetrics suggestion

* better explanation
2018-05-17 07:02:28 -04:00
Dan Field
919e8c211f
Support for TwoPointConical gradients (#5275) 2018-05-16 19:27:44 -04:00
Matan Lurey
be6c51735c
Fix documentation mistake in painting.dart (#5236)
s/`[red]`/_correct color_.
2018-05-15 08:00:30 -07:00
Jason Simmons
bff0e0d597
Allow Canvas.saveLayer without bounds (#5240)
Fixes https://github.com/flutter/flutter/issues/17497
2018-05-11 15:18:35 -07:00
Ben Konyi
39c02c4dc9
Fixed Windows build after Blink removal (#5230) 2018-05-10 17:21:12 -07:00
Jason Simmons
4a4cff96d4
Remove Blink code (#5218)
Fixes https://github.com/flutter/flutter/issues/12212
2018-05-10 15:57:29 -07:00
Jason Simmons
11d50441a6
Provide an SkPaint that describes the background of a text style (#5153)
Fixes https://github.com/flutter/flutter/issues/11961
2018-05-09 11:36:52 -07:00
Alexander Aprelev
9e4c5d0e1f
Roll dart sdk to e6d7d67f4b35556805dd083fed15bf3ed41f7e33. (#5165)
* Roll dart sdk to e6d7d67f4b35556805dd083fed15bf3ed41f7e33.

Changes since last dart roll:

```
e6d7d67f4b Revert 4f18af12c7c6d53f02cf32cb9b5ea848b86e1d77 as it causes test breakages.
4877587346 [GN] Uses dart_action.gni instead of compiled_action.gni.
4b89ba24fb Meta CHANGELOG markdown cleanup.
3d688deba7 Bump analysis server version to 1.20.2
0dc81ae4eb Publish package:meta 1.1.5
7e54844fe7 [vm] Fix build for gcc 7.3.0.
9d10a6ad4a Issue 33034. Fix statement completion with missing condition right parenthesis.
3fd2d5fb05 [vm] Use compiler warnings to insist callers check for errors from Dart_Invoke*/Load*/Compile*.
afb490adbc [dart:io] Provide modern Dart-styled constants
2929b71aa2 [kernel/vm] Address follow-up review comments for bytecode generation
73768a5342 General TypeInfo and IdentifierContext cleanup
e93b2ee250 Improve typedef identifier recovery
46a9ed0617 Added example about calling a tear-off with a wrong-shape argument list
0c839cf3f8 [fasta] Add 'as' expressions to the Forest API
16f6ce2fee [release] Prepare changelog for 2.0.0-dev.53.0
d13bf49870 Check type-variable bounds on generic methods
794fe1e14f Add stacktrace tests for synchronous async
fb779df11c [frontend-server] Disable depfile test on Windows.
```

* Adjust gn-scripts to accommodate 487758734695e7a701325b80178465ebbd0fafdd refactoring.
2018-05-03 15:05:50 -07:00
Yegor
d5c1117170
Roll dart to 011676641a8b4b77bb372384c712709cbf037675 (#5146)
* Roll Dart to 011676641a8b4b77bb372384c712709cbf037675.

Reverts b6be9377c58c488afea042a1b0ed8910b158c319 and uses Dart_NewExternalTypedDataWithFinalizer.

* update license goldens
2018-05-01 17:45:38 -07:00
Ryan Macnak
2812ea3ed3
Define Uri.base as CWD to match the standalone Dart VM. (#5137)
Bug: https://github.com/flutter/flutter/issues/17118
2018-05-01 09:30:30 -07:00
Chinmay Garde
110bce4fde
Use the GPU object constructor to create a gradient shader. (#5136)
Fixes build break introduced in 33aaf6fc2f9185aff37683ceaa5c66ec4ea9f916.
2018-04-30 17:06:59 -07:00
Victor Choueiri
33aaf6fc2f Enable sweep gradients (#4950)
* Enable sweep gradients

* Use _matrix4IsValid

* Add assert for startAngle < endAngle

* Use radians for startAngle and endAngle

* Update AUTHORS

* Better assert on matrix4IsValid
2018-04-30 15:58:53 -07:00
Greg Spencer
cf91f89c84
Adding Color.alphaBlend (#5119)
This is helpful for some Material Design widgets, which are specified as a semi-transparent color over top of a "material". In some cases, the resulting alpha-blended color can be used instead of compositing an additional shape with an opacity.

This new Color.alphaBlend function mimics the alpha blending function, and creates the resulting combined color. The optimization only works for solid color shapes that have the same geometry, of course.
2018-04-30 15:20:29 -07:00
Chinmay Garde
4d106f8520
In case of empty Dart data responses, don’t call the buffer method on null. (#5114)
Fixes regression introduced in https://github.com/flutter/engine/pull/5101.
2018-04-27 15:22:16 -07:00
Jason Simmons
b6be9377c5
Create message response external typed data objects as Uint8Lists (#5101)
PlatformMessageResponseDart will wrap large responses in Dart external typed
data objects in order to avoid copying the data into a new buffer.

Previously these objects were created with the Dart_TypedData_kByteData type.
A weak persistent handle is then associated with the ByteData to provide a
finalizer that deletes the raw buffer.  However, the Dart VM could call
finalizer on the ByteData even if references still existed to the Dart ByteBuffer
object backing the ByteData.  The ByteBuffer would then be referencing a deleted
raw buffer.

This PR prevents that scenario by creating a Dart_TypedData_kUint8 object,
attaching the finalizer to that object, and then wrapping it in a ByteData.
2018-04-26 17:49:51 -07:00