Backed out changeset da009889019a (bug 1842478) for causing build bustage in gfx/layers/AnimationInfo.cpp CLOSED TREE

This commit is contained in:
Sandor Molnar 2023-07-23 16:59:19 +03:00
Родитель 7d6e837414
Коммит 290f09f319
20 изменённых файлов: 220 добавлений и 173 удалений

Просмотреть файл

@ -9,6 +9,7 @@ const {
add_task(async function () {
await pushPref("layout.css.backdrop-filter.enabled", true);
await pushPref("layout.css.individual-transform.enabled", true);
await pushPref("layout.css.color-mix.enabled", true);
await addTab("about:blank");
await performTest();

Просмотреть файл

@ -5,6 +5,7 @@ prefs =
dom.animations.mainthread-synchronization-with-geometric-animations=true
gfx.omta.background-color=true
layout.css.basic-shape-xywh.enabled=true
layout.css.individual-transform.enabled=true
layout.css.motion-path.enabled=true
layout.css.motion-path-basic-shapes.enabled=true
layout.css.motion-path-coord-box.enabled=true

Просмотреть файл

@ -7,6 +7,7 @@ prefs =
dom.animations-api.timelines.enabled=true
gfx.omta.background-color=true
layout.css.motion-path.enabled=true
layout.css.individual-transform.enabled=true
layout.css.scroll-driven-animations.enabled=true
gfx.font_loader.delay=0
# Support files for chrome tests that we want to load over HTTP need

Просмотреть файл

@ -183,9 +183,9 @@ load 1509123.html
pref(widget.windows.window_occlusion_tracking.enabled,false) load 1494062-blob-image-wraplist-clip.html # Bug 1819154
load texture-allocator-zero-region.html
load 1524418.html
load 1529149.html
pref(layout.css.individual-transform.enabled,true) load 1529149.html
load 1541113.html
load 1547169.html
pref(layout.css.individual-transform.enabled,true) load 1547169.html
load 1535657.html
load 1566206.html
load 1615141.html

Просмотреть файл

@ -517,7 +517,7 @@ load 1506314.html
load 1507244.html
load 1510080.html
load 1510485.html
load 1511442.html
pref(layout.css.individual-transform.enabled,true) load 1511442.html
load 1511535.html
load 1511563.html
load 1516286-empty-mask.html

Просмотреть файл

@ -1,6 +1,7 @@
[DEFAULT]
prefs =
dom.window.sizeToContent.enabled=true
layout.css.individual-transform.enabled=true
layout.css.motion-path.enabled=true
layout.css.page-size.enabled=true
skip-if = os == 'android'

Просмотреть файл

@ -149,7 +149,7 @@ fails == translate-rounding-3.html translate-rounding-viewport-ref.html # bug 13
== invalidate-transform-1.html invalidate-transform-1-ref.html
== invalidate-svg-scale-1.html invalidate-svg-scale-1-ref.html
# Bug 1526847
== animate-layer-scale-inherit-4.html animate-layer-scale-inherit-4-ref.html
pref(layout.css.individual-transform.enabled,true) == animate-layer-scale-inherit-4.html animate-layer-scale-inherit-4-ref.html
fuzzy-if(winWidget,0-1,0-1000) == 1569215-1.html 1569215-1-ref.html
test-pref(layout.css.zoom-transform-hack.enabled,true) == zoom-hack-1.html zoom-hack-ref.html

Просмотреть файл

@ -312,7 +312,7 @@ load 1580307.html
load 1581579.html
skip-if(release_or_beta) pref(dom.paintWorklet.enabled,true) load 1593766.html # bug 1581896
pref(layout.css.motion-path.enabled,true) load 1594949.html
pref(layout.css.motion-path.enabled,true) load 1594960.html
pref(layout.css.motion-path.enabled,true) pref(layout.css.individual-transform.enabled,true) load 1594960.html
load 1586444.html
load 1599286.html
pref(layout.css.motion-path.enabled,true) load 1609786.html

Просмотреть файл

@ -0,0 +1,65 @@
<!doctype html>
<meta charset=utf-8>
<title>Test for Bug 1207734 (individual transforms)</title>
<!--
FIXME: This is only here in a separate file since it needs the
layout.css.individual-transform.enabled pref to be set when it runs and the
pref= annotation in mochitest.ini doesn't work on Android (bug 1393326).
Once we turn on that pref by default or fix bug 1393326 we can move this back
into test_specified_value_serialization.html.
-->
<script>
const is = opener.is.bind(opener);
function finish() {
const o = opener;
self.close();
o.SimpleTest.finish();
}
function runTest() {
// Test for rotate property serialization.
[
[" 90deg ", "90deg"],
[" 100grad ", "100grad"],
[" 100gRaD ", "100grad"],
[" 0.25turn ", "0.25turn"],
[" 0.25tUrN ", "0.25turn"],
[" 1.57RaD ", "1.57rad"],
].forEach(function(arr) {
document.documentElement.style.rotate = arr[0];
is(document.documentElement.style.rotate, arr[1],
"bug-1207734: incorrect rotate serialization");
});
document.documentElement.style.rotate = "";
// Test for translate property serialization.
[
[" 50% 5px 6px ", "50% 5px 6px"],
[" 50% 10px 100px ", "50% 10px 100px"],
[" 4px 5px ", "4px 5px"],
[" 10% 10% 99px ", "10% 10% 99px"],
[" 50px ", "50px"],
].forEach(function(arr) {
document.documentElement.style.translate = arr[0];
is(document.documentElement.style.translate, arr[1],
"bug-1207734: incorrect translate serialization");
});
document.documentElement.style.translate = "";
// Test for scale property serialization.
[
[" 10 ", "10"],
[" 10 20.5 ", "10 20.5"],
[" 10 20 30 ", "10 20 30"],
].forEach(function(arr) {
document.documentElement.style.scale = arr[0];
is(document.documentElement.style.scale, arr[1],
"bug-1207734: incorrect scale serialization");
});
document.documentElement.style.scale = "";
}
runTest();
finish();
</script>

Просмотреть файл

@ -9,6 +9,7 @@ prefs =
gfx.omta.background-color=true
gfx.font_loader.delay=0
layout.css.container-queries.enabled=true
layout.css.individual-transform.enabled=true
layout.css.motion-path.enabled=true
layout.css.motion-path-ray.enabled=true
layout.css.motion-path-basic-shapes.enabled=true
@ -374,6 +375,7 @@ support-files = file_shared_sheet_caching.css file_shared_sheet_caching.html
fail-if = xorigin
[test_shorthand_property_getters.html]
[test_specified_value_serialization.html]
support-files = file_specified_value_serialization_individual_transforms.html
[test_style_attr_listener.html]
[test_style_attribute_quirks.html]
[test_style_attribute_standards.html]

Просмотреть файл

@ -11817,120 +11817,122 @@ function get_computed_value(cs, property) {
}
}
gCSSProperties.rotate = {
domProp: "rotate",
inherited: false,
type: CSS_TYPE_LONGHAND,
initial_values: ["none"],
other_values: [
"45deg",
"45grad",
"72rad",
"0.25turn",
".57rad",
"0 0 0 0rad",
"0 0 1 45deg",
"0 0 1 0rad",
"0rad 0 0 1",
"10rad 10 20 30",
"x 10rad",
"y 10rad",
"z 10rad",
"10rad x",
"10rad y",
"10rad z",
/* valid calc() values */
"calc(1) 0 0 calc(45deg + 5rad)",
"0 1 0 calc(400grad + 1rad)",
"calc(0.5turn + 10deg)",
],
invalid_values: [
"0",
"7",
"0, 0, 1, 45deg",
"0 0 45deg",
"0 0 20rad",
"0 0 0 0",
"x x 10rad",
"x y 10rad",
"0 0 1 10rad z",
"0 0 1 z 10rad",
"z 0 0 1 10rad",
"0 0 z 1 10rad",
/* invalid calc() values */
"0.5 1 0 calc(45deg + 10)",
"calc(0.5turn + 10%)",
],
};
if (IsCSSPropertyPrefEnabled("layout.css.individual-transform.enabled")) {
gCSSProperties.rotate = {
domProp: "rotate",
inherited: false,
type: CSS_TYPE_LONGHAND,
initial_values: ["none"],
other_values: [
"45deg",
"45grad",
"72rad",
"0.25turn",
".57rad",
"0 0 0 0rad",
"0 0 1 45deg",
"0 0 1 0rad",
"0rad 0 0 1",
"10rad 10 20 30",
"x 10rad",
"y 10rad",
"z 10rad",
"10rad x",
"10rad y",
"10rad z",
/* valid calc() values */
"calc(1) 0 0 calc(45deg + 5rad)",
"0 1 0 calc(400grad + 1rad)",
"calc(0.5turn + 10deg)",
],
invalid_values: [
"0",
"7",
"0, 0, 1, 45deg",
"0 0 45deg",
"0 0 20rad",
"0 0 0 0",
"x x 10rad",
"x y 10rad",
"0 0 1 10rad z",
"0 0 1 z 10rad",
"z 0 0 1 10rad",
"0 0 z 1 10rad",
/* invalid calc() values */
"0.5 1 0 calc(45deg + 10)",
"calc(0.5turn + 10%)",
],
};
gCSSProperties.translate = {
domProp: "translate",
inherited: false,
type: CSS_TYPE_LONGHAND,
prerequisites: { width: "10px", height: "10px", display: "block" },
initial_values: ["none"],
other_values: [
"-4px",
"3px",
"4em",
"50%",
"4px 5px 6px",
"4px 5px",
"50% 5px 6px",
"50% 10% 6em",
/* valid calc() values */
"calc(5px + 10%)",
"calc(0.25 * 5px + 10% / 3)",
"calc(5px - 10% * 3)",
"calc(5px - 3 * 10%) 50px",
"-50px calc(5px - 10% * 3)",
"10px calc(min(5px,10%))",
],
invalid_values: [
"1",
"-moz-min(5px,10%)",
"4px, 5px, 6px",
"3px 4px 1px 7px",
"4px 5px 10%",
/* invalid calc() values */
"calc(max(5px,10%) 10%)",
"calc(nonsense)",
],
};
gCSSProperties.scale = {
domProp: "scale",
inherited: false,
type: CSS_TYPE_LONGHAND,
initial_values: ["none"],
other_values: [
"10",
"10%",
"10 20",
"10% 20%",
"10 20 30",
"10% 20% 30%",
"10 20% 30",
"-10",
"-10%",
"-10 20",
"-10% 20%",
"-10 20 -30",
"-10% 20% -30%",
"-10 20% -30",
"0 2.0",
/* valid calc() values */
"calc(1 + 2)",
"calc(10) calc(20) 30",
],
invalid_values: [
"10px",
"10deg",
"10, 20, 30",
/* invalid calc() values */
"calc(1 + 20%)",
"10 calc(1 + 10px)",
],
};
gCSSProperties.translate = {
domProp: "translate",
inherited: false,
type: CSS_TYPE_LONGHAND,
prerequisites: { width: "10px", height: "10px", display: "block" },
initial_values: ["none"],
other_values: [
"-4px",
"3px",
"4em",
"50%",
"4px 5px 6px",
"4px 5px",
"50% 5px 6px",
"50% 10% 6em",
/* valid calc() values */
"calc(5px + 10%)",
"calc(0.25 * 5px + 10% / 3)",
"calc(5px - 10% * 3)",
"calc(5px - 3 * 10%) 50px",
"-50px calc(5px - 10% * 3)",
"10px calc(min(5px,10%))",
],
invalid_values: [
"1",
"-moz-min(5px,10%)",
"4px, 5px, 6px",
"3px 4px 1px 7px",
"4px 5px 10%",
/* invalid calc() values */
"calc(max(5px,10%) 10%)",
"calc(nonsense)",
],
};
gCSSProperties.scale = {
domProp: "scale",
inherited: false,
type: CSS_TYPE_LONGHAND,
initial_values: ["none"],
other_values: [
"10",
"10%",
"10 20",
"10% 20%",
"10 20 30",
"10% 20% 30%",
"10 20% 30",
"-10",
"-10%",
"-10 20",
"-10% 20%",
"-10 20 -30",
"-10% 20% -30%",
"-10 20% -30",
"0 2.0",
/* valid calc() values */
"calc(1 + 2)",
"calc(10) calc(20) 30",
],
invalid_values: [
"10px",
"10deg",
"10, 20, 30",
/* invalid calc() values */
"calc(1 + 20%)",
"10 calc(1 + 10px)",
],
};
}
gCSSProperties["touch-action"] = {
domProp: "touchAction",

Просмотреть файл

@ -266,49 +266,15 @@
p.remove();
})();
(function test_bug_1207734 () {
// Test for rotate property serialization.
[
[" 90deg ", "90deg"],
[" 100grad ", "100grad"],
[" 100gRaD ", "100grad"],
[" 0.25turn ", "0.25turn"],
[" 0.25tUrN ", "0.25turn"],
[" 1.57RaD ", "1.57rad"],
].forEach(function(arr) {
document.documentElement.style.rotate = arr[0];
is(document.documentElement.style.rotate, arr[1],
"bug-1207734: incorrect rotate serialization");
});
document.documentElement.style.rotate = "";
SimpleTest.waitForExplicitFinish();
SpecialPowers.pushPrefEnv(
{
set: [['layout.css.individual-transform.enabled', true]],
},
() =>
window.open('file_specified_value_serialization_individual_transforms.html')
);
// Test for translate property serialization.
[
[" 50% 5px 6px ", "50% 5px 6px"],
[" 50% 10px 100px ", "50% 10px 100px"],
[" 4px 5px ", "4px 5px"],
[" 10% 10% 99px ", "10% 10% 99px"],
[" 50px ", "50px"],
].forEach(function(arr) {
document.documentElement.style.translate = arr[0];
is(document.documentElement.style.translate, arr[1],
"bug-1207734: incorrect translate serialization");
});
document.documentElement.style.translate = "";
// Test for scale property serialization.
[
[" 10 ", "10"],
[" 10 20.5 ", "10 20.5"],
[" 10 20 30 ", "10 20 30"],
].forEach(function(arr) {
document.documentElement.style.scale = arr[0];
is(document.documentElement.style.scale, arr[1],
"bug-1207734: incorrect scale serialization");
});
document.documentElement.style.scale = "";
})()
</script>
</pre>
</body>

Просмотреть файл

@ -350,15 +350,6 @@ var supported_properties = {
test_length_transition, test_percent_transition,
test_length_clamped, test_percent_clamped,
],
"rotate": [
test_rotate_transition
],
"scale": [
test_scale_transition
],
"translate": [
test_translate_transition
],
};
if (IsCSSPropertyPrefEnabled("layout.css.backdrop-filter.enabled")) {
@ -369,6 +360,12 @@ if (IsCSSPropertyPrefEnabled("layout.css.font-variations.enabled")) {
supported_properties["font-variation-settings"] = [ test_font_variations_transition ];
}
if (IsCSSPropertyPrefEnabled("layout.css.individual-transform.enabled")) {
supported_properties["rotate"] = [ test_rotate_transition ];
supported_properties["scale"] = [ test_scale_transition ];
supported_properties["translate"] = [ test_translate_transition ];
}
if (IsCSSPropertyPrefEnabled("layout.css.contain-intrinsic-size.enabled")) {
supported_properties["contain-intrinsic-width"] = [ test_length_transition, test_auto_with_length_transition ];
supported_properties["contain-intrinsic-height"] = supported_properties["contain-intrinsic-width"];

Просмотреть файл

@ -8545,6 +8545,12 @@
value: true
mirror: always
# Is support for CSS individual transform enabled?
- name: layout.css.individual-transform.enabled
type: bool
value: true
mirror: always
# Is support for CSS initial-letter property enabled?
- name: layout.css.initial-letter.enabled
type: bool

Просмотреть файл

@ -179,6 +179,7 @@ ${helpers.predefined_type(
animation_value_type="ComputedValue",
boxed=True,
flags="CAN_ANIMATE_ON_COMPOSITOR",
gecko_pref="layout.css.individual-transform.enabled",
spec="https://drafts.csswg.org/css-transforms-2/#individual-transforms",
servo_restyle_damage = "reflow_out_of_flow",
)}
@ -191,6 +192,7 @@ ${helpers.predefined_type(
animation_value_type="ComputedValue",
boxed=True,
flags="CAN_ANIMATE_ON_COMPOSITOR",
gecko_pref="layout.css.individual-transform.enabled",
spec="https://drafts.csswg.org/css-transforms-2/#individual-transforms",
servo_restyle_damage = "reflow_out_of_flow",
)}
@ -203,6 +205,7 @@ ${helpers.predefined_type(
animation_value_type="ComputedValue",
boxed=True,
flags="CAN_ANIMATE_ON_COMPOSITOR",
gecko_pref="layout.css.individual-transform.enabled",
spec="https://drafts.csswg.org/css-transforms-2/#individual-transforms",
servo_restyle_damage="reflow_out_of_flow",
)}

Просмотреть файл

@ -0,0 +1,2 @@
[position-absolute-dynamic-static-position-table-cell.html]
prefs: [layout.css.individual-transform.enabled:true]

Просмотреть файл

@ -1,2 +1,2 @@
prefs: [dom.animations-api.compositing.enabled:true, layout.css.backdrop-filter.enabled:true]
prefs: [layout.css.individual-transform.enabled:true, dom.animations-api.compositing.enabled:true, layout.css.backdrop-filter.enabled:true]
leak-threshold: [default:51200]

Просмотреть файл

@ -1 +1 @@
prefs: [layout.css.motion-path.enabled:true, dom.animations-api.core.enabled:true, layout.css.motion-path-ray.enabled:true, layout.css.motion-path-offset-position.enabled:true, layout.css.motion-path-basic-shapes.enabled:true, layout.css.motion-path-coord-box.enabled:true, layout.css.basic-shape-xywh.enabled:true]
prefs: [layout.css.motion-path.enabled:true, layout.css.individual-transform.enabled:true, dom.animations-api.core.enabled:true, layout.css.motion-path-ray.enabled:true, layout.css.motion-path-offset-position.enabled:true, layout.css.motion-path-basic-shapes.enabled:true, layout.css.motion-path-coord-box.enabled:true, layout.css.basic-shape-xywh.enabled:true]

Просмотреть файл

@ -1 +1 @@
prefs: [layout.css.motion-path.enabled:true]
prefs: [layout.css.individual-transform.enabled:true, layout.css.motion-path.enabled:true]

Просмотреть файл

@ -1 +1 @@
prefs: [layout.css.scroll-driven-animations.enabled:true]
prefs: [layout.css.scroll-driven-animations.enabled:true, layout.css.individual-transform.enabled:true]