Automatic update from web-platform-tests[css-layout-api] Allow passing of serialized data between parent<->child.
This allow arbitary parent<->child communation during layout. A parent
can send data to a child via:
// parent
const fragment = yield child.layoutNextFragment({data});
// child
*layout(children, edges, constraints, style) {
const data = constraints.data; // receive data.
}
And child to parent via:
// child
*layout() {
return {data};
}
// parent
const fragment = yield child.layoutNextFragment();
const data = fragment.data; // receive data.
As the parent and child layouts may be invoked in different worklet
global scopes, and don't allow data shared, the serialization of data
uses "kForStorage" which means that SharedArrayBuffers aren't allowed
in the serialization.
Serialization also occurs so that we are able to cache results.
Bug: 726125
Change-Id: Ib7e81b5778cef3af2c2f8a1ccef749f1d2ba4dfa
Reviewed-on: https://chromium-review.googlesource.com/1072150
Reviewed-by: Kentaro Hara <[email protected]>
Reviewed-by: Morten Stenshorne <[email protected]>
Commit-Queue: Ian Kilpatrick <[email protected]>
Cr-Commit-Position: refs/heads/master@{#563235}
--
wpt-commits: 8c8238ca96f913c1b90f838def7f9cf0253c0113
wpt-pr: 11166
Automatic update from web-platform-tests[css-layout-api] Populate children, and pass into layout() function
This introduces the LayoutChild API surface, (which only has a styleMap
accessor currently).
Each LayoutBox which is a child of a LayoutCustom will hold onto a
LayoutChild object, acting as the script interface for the web
developer.
Bug: 726125
Change-Id: Iecdb01a38c0712dcda063b485c4207bde59f3995
Reviewed-on: https://chromium-review.googlesource.com/933092
Commit-Queue: Ian Kilpatrick <[email protected]>
Reviewed-by: Morten Stenshorne <[email protected]>
Reviewed-by: Rune Lillesveen <[email protected]>
Reviewed-by: Koji Ishii <[email protected]>
Cr-Commit-Position: refs/heads/master@{#539928}
wpt-commits: 41ab079dfcde76aebbde5660fe3e417447e61f80
wpt-pr: 9680
wpt-commits: 41ab079dfcde76aebbde5660fe3e417447e61f80
wpt-pr: 9680