Граф коммитов

14201 Коммитов

Автор SHA1 Сообщение Дата
Ziran Sun 65711751b2 Bug 1778296 - make contain-intrinsic-size *animatable*. r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D151231
2022-07-11 08:37:44 +00:00
David Shin d1e16d47d7 Bug 1766041: Part 5: C++ `ComputedTimingFunction` uses Rust's timing function calculation. r=emilio
This was made economical by having Rust's computed `easing::TimingFunction` use
a fully resolved function for `linear(...)` easing, as per draft resolution from
https://github.com/w3c/csswg-drafts/issues/7415

Differential Revision: https://phabricator.services.mozilla.com/D151295
2022-07-09 17:33:59 +00:00
David Shin 5da2d56d12 Bug 1766041: Part 4: Port bezier edge cases handling from C++ to Rust. r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D150569
2022-07-09 17:33:58 +00:00
David Shin d360f1fee3 Bug 1766041: Part 3: Migrate C++ `BeforeFlag` to that of Rust's. r=boris
Differential Revision: https://phabricator.services.mozilla.com/D150567
2022-07-09 17:33:58 +00:00
David Shin 5c56dc3a60 Bug 1766041: Part 2: Update rust's step function basd on C++ `ComputedTimingFunction`. r=boris
Differential Revision: https://phabricator.services.mozilla.com/D150566
2022-07-09 17:33:57 +00:00
David Shin 40f1452af5 Bug 1766041: Part 1: Move Rust animation to `ComputedTimingFunction`. r=boris
Differential Revision: https://phabricator.services.mozilla.com/D150565
2022-07-09 17:33:57 +00:00
Csoregi Natalia 33193d6158 Backed out 5 changesets (bug 1766041) for gtest failures on APZCBasicTester. CLOSED TREE
Backed out changeset 3b0cd4ee7d1e (bug 1766041)
Backed out changeset 5de0ed4fd59b (bug 1766041)
Backed out changeset cc7ffb683e8a (bug 1766041)
Backed out changeset ce5a895e7a06 (bug 1766041)
Backed out changeset 315578c436ca (bug 1766041)
2022-07-08 03:12:42 +03:00
David Shin 00ee70f348 Bug 1766041: Part 5: C++ `ComputedTimingFunction` uses Rust's timing function calculation. r=emilio
This was made economical by having Rust's computed `easing::TimingFunction` use
a fully resolved function for `linear(...)` easing, as per draft resolution from
https://github.com/w3c/csswg-drafts/issues/7415

Differential Revision: https://phabricator.services.mozilla.com/D151295
2022-07-07 22:52:59 +00:00
David Shin 9dfbcf5b60 Bug 1766041: Part 4: Port bezier edge cases handling from C++ to Rust. r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D150569
2022-07-07 22:52:59 +00:00
David Shin 07b055639d Bug 1766041: Part 3: Migrate C++ `BeforeFlag` to that of Rust's. r=boris
Differential Revision: https://phabricator.services.mozilla.com/D150567
2022-07-07 22:52:58 +00:00
David Shin 0c20ef85f5 Bug 1766041: Part 2: Update rust's step function basd on C++ `ComputedTimingFunction`. r=boris
Differential Revision: https://phabricator.services.mozilla.com/D150566
2022-07-07 22:52:58 +00:00
David Shin 6a09761348 Bug 1766041: Part 1: Move Rust animation to `ComputedTimingFunction`. r=boris
Differential Revision: https://phabricator.services.mozilla.com/D150565
2022-07-07 22:52:57 +00:00
Emilio Cobos Álvarez 2c2f20586e Bug 1778396 - Add color-mix to DevTools autocomplete. r=nchevobbe
Differential Revision: https://phabricator.services.mozilla.com/D151180
2022-07-07 10:29:59 +00:00
Emilio Cobos Álvarez aa9b6a0a65 Bug 1778062 - Minor indentation fix. DONTBUILD
MANUAL PUSH: White-space only change
2022-07-06 13:59:15 +02:00
Ziran Sun 435c380565 Bug 1778062 - Add support for parsing the `contain-intrinsic-size` property from the CSS-sizing specification. r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D151001
2022-07-06 11:47:51 +00:00
Emilio Cobos Álvarez a7e9f1597b Bug 1771150 - Make fullscreen modal. r=smaug
As per https://github.com/w3c/csswg-drafts/issues/7311.

Differential Revision: https://phabricator.services.mozilla.com/D150335
2022-07-06 00:16:28 +00:00
David Shin bdcfb83f13 Bug 1775351: Part 2: `linear(...)` easing: Simplify piecewise linear implementation given parsing simplification. r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D150163
2022-06-28 11:31:34 +00:00
David Shin 9b9505a23c Bug 1775351: Part 1: `linear(...)` easing: Parsing should split a linear stop value into two for entries with both `linear-stop-length` set. r=emilio
This brings the behaviour inline with `linear-gradient(...)`

Differential Revision: https://phabricator.services.mozilla.com/D149926
2022-06-28 11:31:34 +00:00
Noemi Erli 5003eb07b7 Backed out changeset 8a9bae22cf24 (bug 1771150) for causing failures in browser_fullscreen_warning.js and test_pointerlock-api.html CLOSED TREE 2022-06-27 17:27:11 +03:00
Emilio Cobos Álvarez 016a64f777 Bug 1771150 - Make fullscreen modal. r=smaug
As per https://github.com/w3c/csswg-drafts/issues/7311.

Differential Revision: https://phabricator.services.mozilla.com/D150335
2022-06-27 10:57:34 +00:00
Cristian Tuns a13498c4a2 Backed out 2 changesets (bug 1775351) for causing build bustages CLOSED TREE
Backed out changeset 4afc18c58426 (bug 1775351)
Backed out changeset e900fb167e26 (bug 1775351)
2022-06-24 13:38:21 -04:00
David Shin 3329d8a011 Bug 1775351: Part 2: `linear(...)` easing: Simplify piecewise linear implementation given parsing simplification. r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D150163
2022-06-24 17:02:40 +00:00
David Shin 53969dc502 Bug 1775351: Part 1: `linear(...)` easing: Parsing should split a linear stop value into two for entries with both `linear-stop-length` set. r=emilio
This brings the behaviour inline with `linear-gradient(...)`

Differential Revision: https://phabricator.services.mozilla.com/D149926
2022-06-24 17:02:39 +00:00
David Shin 1e0b25bad0 Bug 1775335: `linear(...)` Easing: First linear entry should Get 0.0 assigned for input if not specified. r=emilio
Previously, had the smallest input value over all entries was assigned. However,
that does not match the behaviour of `linear-gradient(...)`, which this easing
function is modeled after.

Differential Revision: https://phabricator.services.mozilla.com/D149916
2022-06-24 13:18:17 +00:00
Emilio Cobos Álvarez c14065f628 Bug 1776162 - Improve LookAndFeel color caching. r=mstange
To be honest, I'm a bit baffled that bug 1773795 caused a performance
regression, but I think it's because the standins codepath is not really
cached, so system colors that are "spoofed" always go through the
massive switch, which could potentially be expensive.

To fix, this, rejigger a bit the caches so that we key on both
color-scheme and use-standins. Also, while at it, make the set of colors
we spoof a single bitflag check, rather than relying on the compiler to
do something potentially smart with it.

I had to shuffle the order of colors around so that the expression to
initialize the bitfield is constexpr (doesn't go over 1 << 64), but
other than that this patch should be relatively straight-forward.

Differential Revision: https://phabricator.services.mozilla.com/D150100
2022-06-23 22:38:02 +00:00
David Shin aca7c3d4df Bug 1773493 - Use Rust's `ComputedTimingFunction` for IPDL. r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D149663
2022-06-23 17:07:13 +00:00
Emilio Cobos Álvarez cbb5b58f4d Bug 1772555 - Use style interpolation code for gradients. r=nical
This ensures they're clamped on Animated -> sRGB conversion, and in the
future we'll have to implement different color spaces so we'll need to
use it anyways.

Differential Revision: https://phabricator.services.mozilla.com/D149792
2022-06-22 23:02:34 +00:00
Iulian Moraru 0ebda972c1 Backed out changeset 003cad9bbcc6 (bug 1772555) for causing reftest failures on bugs/1315113-1.html. 2022-06-22 22:00:53 +03:00
Emilio Cobos Álvarez 827fe3a33e Bug 1772555 - Use style interpolation code for gradients. r=nical
This ensures they're clamped on Animated -> sRGB conversion, and in the
future we'll have to implement different color spaces so we'll need to
use it anyways.

Differential Revision: https://phabricator.services.mozilla.com/D149792
2022-06-22 17:00:56 +00:00
Martin Robinson f85b73bf84 Bug 1463600 - Implement CSS 'contain: style' r=emilio
Add an implementation of CSS `contain: style`. This introduces two new
data structures, the ContainStyleScope and ContainStyleScopeManager.

ContainStyleScope manages one `contain: style` "world" which has its own
counter and quote lists. The contents of these lists depend on their
parent scopes, but are not affected by their children.
ContainStyleScopeManager manages a tree of scopes starting at a root
scope which is outside of any `contain: style` element.

Scopes are stored in a hash table that is keyed off of the nsIContent
which establishes the `contain: style` scope. When modifying quote or
content lists, the ContainStyleScopeManager is responsible for finding
the appropriate `contain: style` scope to modify.

Perhaps the most complex part of this is that counters and quotes have
read access to the state of counters and quotes that are in ancestor
`contain: style` scopes. In the case of counters, USE nodes that are at
the beginning of counter lists might have a counter scope that starts in
an ancestor `contain: style` scope. When nsCounterNode::SetScope() is
called, the code may look upward in the `contain: style` scope tree to
find the start of the counter scope. In the case of quotes, the first
node in the quote list must look for the state of quotes in ancestor
`contain: style` scopes.

Differential Revision: https://phabricator.services.mozilla.com/D149508
2022-06-22 16:16:59 +00:00
Bogdan Szekely b56ae513c7 Backed out changeset 86e9449aba35 (bug 1463600) for causing xpcshell failures on test_css-properties-db.js 2022-06-22 15:35:33 +03:00
Martin Robinson 83640bbee6 Bug 1463600 - Implement CSS 'contain: style' r=emilio
Add an implementation of CSS `contain: style`. This introduces two new
data structures, the ContainStyleScope and ContainStyleScopeManager.

ContainStyleScope manages one `contain: style` "world" which has its own
counter and quote lists. The contents of these lists depend on their
parent scopes, but are not affected by their children.
ContainStyleScopeManager manages a tree of scopes starting at a root
scope which is outside of any `contain: style` element.

Scopes are stored in a hash table that is keyed off of the nsIContent
which establishes the `contain: style` scope. When modifying quote or
content lists, the ContainStyleScopeManager is responsible for finding
the appropriate `contain: style` scope to modify.

Perhaps the most complex part of this is that counters and quotes have
read access to the state of counters and quotes that are in ancestor
`contain: style` scopes. In the case of counters, USE nodes that are at
the beginning of counter lists might have a counter scope that starts in
an ancestor `contain: style` scope. When nsCounterNode::SetScope() is
called, the code may look upward in the `contain: style` scope tree to
find the start of the counter scope. In the case of quotes, the first
node in the quote list must look for the state of quotes in ancestor
`contain: style` scopes.

Differential Revision: https://phabricator.services.mozilla.com/D149508
2022-06-22 10:42:34 +00:00
Emilio Cobos Álvarez 4c5f20179e Bug 1775247 - Implement AccentColor/AccentColorText and remove -moz-prefixed version of the color. r=mstange
As per https://github.com/w3c/csswg-drafts/issues/7347.

Mostly renaming, doesn't change behavior other than exposing the new
color keywords (tested in wpt).

Differential Revision: https://phabricator.services.mozilla.com/D149876
2022-06-22 09:45:06 +00:00
David Shin 8c02818079 Bug 1771980 - Refactor function parsing branches for `specified::easing::TimingFunction`. r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D149756
2022-06-20 17:45:03 +00:00
Emilio Cobos Álvarez 5a2d3c5d54 Bug 1774946 - Check for allowed colors recursively in forced-colors mode. r=jwatt
Differential Revision: https://phabricator.services.mozilla.com/D149733
2022-06-20 14:07:12 +00:00
Tiaan Louw 2a83b583b1 Bug 1771896 - Add simple parsing and matching support for :has r=emilio
Parsing is behind a config value `layout.css.has-selectors.enabled`. This
change does not support p:has(> a) combinators, but will handle them
gracefully, just not matching on them.

Differential Revision: https://phabricator.services.mozilla.com/D149515
2022-06-20 08:53:02 +00:00
Emilio Cobos Álvarez 46ef76a7d7 Bug 1774791 - Fix grid shorthand parsing to not incorrectly ignore the last token in one case. r=dholbert
Differential Revision: https://phabricator.services.mozilla.com/D149666
2022-06-17 20:50:37 +00:00
Mike Hommey a211cd2aea Bug 1774501 - Update stylo to itertools:0.10, itoa:1.0 and toml:0.5. r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D149454
2022-06-16 20:44:03 +00:00
Jonathan Kew 64fcd19655 Bug 1771215 - Only accept the CSS2 font-variant values (normal/small-caps) in the font shorthand; CSS Fonts 3/4 font-variant additions are not allowed. r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D149440
2022-06-16 12:13:54 +00:00
Emilio Cobos Álvarez bf4306b284 Bug 1774224 - Fix dynamic viewport size. r=hiro
Differential Revision: https://phabricator.services.mozilla.com/D149275
2022-06-15 09:55:57 +00:00
Emilio Cobos Álvarez d43049661f Bug 1773484 - Make viewport-relative units zoomable via "zoom text only". r=boris
They're not font relative, so it we probably want them to be zoomed.

Differential Revision: https://phabricator.services.mozilla.com/D148796
2022-06-14 08:38:11 +00:00
Boris Chiou 2b8751f919 Bug 1754897 - Part 4: Hook named scroll timelines to animation-timeline. r=emilio
Basically, animation-timeline could be
1. auto
2. none
3. <timeline-name>

We extend the <timeline-name> to cover both @scroll-timeline rule and
scroll-timeline-name property. We check @scroll-timeline rule first. If
it doesn't exist, we check scroll-timeline-name of the element itself,
the previous silbings, and their ancestors.

Differential Revision: https://phabricator.services.mozilla.com/D146358
2022-06-13 20:26:45 +00:00
Boris Chiou f1b5d17847 Bug 1754897 - Part 3: Support scroll-timeline shorthand in style system. r=emilio
Implement
"scroll-timeline: <'scroll-timeline-axis'> || <'scroll-timeline-name'>".

Differential Revision: https://phabricator.services.mozilla.com/D146020
2022-06-13 20:26:45 +00:00
Boris Chiou e9d0888406 Bug 1754897 - Part 2: Support scroll-timeline-axis longhand in style system. r=emilio
Implement "scroll-timeline-axis: block | inline | vertical | horizontal".

Differential Revision: https://phabricator.services.mozilla.com/D146019
2022-06-13 20:26:45 +00:00
Boris Chiou cd0ef479a6 Bug 1754897 - Part 1: Support scroll-timeline-name longhand in style system. r=emilio
Implement "scroll-timeline-name: none | <custom-ident>".

Differential Revision: https://phabricator.services.mozilla.com/D146018
2022-06-13 20:26:44 +00:00
Emilio Cobos Álvarez 9fc2aa47fc Bug 1773558 - Move fixed-point font types to Rust. r=layout-reviewers,jfkthame
Now that cbindgen and rust support const generics, it seems more simple.

This centralizes all the relevant font constants etc in rust and avoids
conversions when going from rust to C++ and vice versa.

Differential Revision: https://phabricator.services.mozilla.com/D148847
2022-06-13 00:59:23 +00:00
Noemi Erli 841e350bc4 Backed out changeset 7585591a9bad (bug 1773558) for causing failures in system-fonts.html 2022-06-12 19:02:33 +03:00
Emilio Cobos Álvarez e441089ca0 Bug 1773558 - Move fixed-point font types to Rust. r=layout-reviewers,jfkthame
Now that cbindgen and rust support const generics, it seems more simple.

This centralizes all the relevant font constants etc in rust and avoids
conversions when going from rust to C++ and vice versa.

Differential Revision: https://phabricator.services.mozilla.com/D148847
2022-06-12 10:48:58 +00:00
Mike Hommey c143e86971 Bug 1773399 - Update derive_more to 0.99.17. r=emilio,gfx-reviewers,nical
Limit its features to those we actually use, which turns out is none for
webrender_api.

Differential Revision: https://phabricator.services.mozilla.com/D148734
2022-06-11 20:34:18 +00:00
Emilio Cobos Álvarez 647a9887bf Bug 1771725 - Add a low-priority selector list for pseudo-classes that have global rules. r=boris
This avoids trying to match those global rules for most elements that
can't match them anyways.

Differential Revision: https://phabricator.services.mozilla.com/D147640
2022-06-09 12:16:26 +00:00
Tiaan Louw 10dbaef1e0 Bug 1768535 - Rename :-moz-modal-dialog to :modal r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D148751
2022-06-09 08:58:52 +00:00
Emilio Cobos Álvarez 47afabb81a Bug 1773070 - While at it use some better names for some bits. r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D148538
2022-06-07 23:09:53 +00:00
Emilio Cobos Álvarez 255763ef57 Bug 1773070 - Unify Gecko and Servo EventState/ElementState bits. r=smaug
Add a dom/base/rust crate called just "dom" where we can share these.

Most of the changes are automatic:

  s/mozilla::EventStates/mozilla::dom::ElementState/
  s/EventStates/ElementState/
  s/NS_EVENT_STATE_/ElementState::/
  s/NS_DOCUMENT_STATE_/DocumentState::/

And so on. This requires a new cbindgen version to avoid ugly casts for
large shifts.

Differential Revision: https://phabricator.services.mozilla.com/D148537
2022-06-07 23:09:52 +00:00
David Shin 14611a24e8 Bug 1764126 - Part 4: Add parsing for linear easing function and gate it behind pref. r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D146839
2022-06-07 11:51:24 +00:00
David Shin e46f5534e2 Bug 1764126 - Part 3: Hook up linear easing calculation for servo and expose it to C++. r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D146838
2022-06-07 11:51:24 +00:00
David Shin c79a8137f5 Bug 1764126 - Part 2: Rust side plumbing work for linear easing function. r=emilio
Add LinearFunction to TimingFunction. Because the linear function is a
variable list of linear stops, the enum is no longer Copyable.

Differential Revision: https://phabricator.services.mozilla.com/D146837
2022-06-07 11:51:24 +00:00
Emilio Cobos Álvarez 9b518ab15c Bug 1772690 - Fix opt builds.
MANUAL PUSH: Trivial build fix CLOSED TREE
2022-06-05 23:42:05 +02:00
Emilio Cobos Álvarez fb05cda721 Bug 1772690 - Add a debug-only ComputedStyle::DumpMatchedRules(). r=dholbert
Differential Revision: https://phabricator.services.mozilla.com/D148336
2022-06-05 21:21:10 +00:00
Emilio Cobos Álvarez b24faeba30 Bug 1750102 - Add an input-region-margin to widgets, and implement it on Linux. r=stransky
Recompute the input region when resizing the widget and so on, and use
it to check for rollups.

Depends on D148211

Differential Revision: https://phabricator.services.mozilla.com/D148222
2022-06-04 12:41:06 +00:00
Emilio Cobos Álvarez 50fea61916 Bug 1770829 - Use ColorMix for interpolated colors in the computed style rather than ComplexColorRatios. r=barret
This among other things preserves the right color-space when
interpolating currentColor.

Differential Revision: https://phabricator.services.mozilla.com/D147512
2022-06-03 19:11:07 +00:00
Marian-Vasile Laza c7d153ca29 Backed out changeset c8b026cff732 (bug 1750102) for causing bc failures on browser_test_autoscrolling_in_extension_popup_window.js. CLOSED TREE 2022-06-03 20:12:55 +03:00
Emilio Cobos Álvarez c6c289ff2d Bug 1750102 - Add an input-region-margin to widgets, and implement it on Linux. r=stransky
Recompute the input region when resizing the widget and so on, and use
it to check for rollups.

Depends on D148211

Differential Revision: https://phabricator.services.mozilla.com/D148222
2022-06-03 10:39:13 +00:00
Emilio Cobos Álvarez 9349aeea85 Bug 1771796 - Remove -moz-scrollbar-thumb-proportional. r=dholbert
It unconditionally matches on all platforms, so it's not returning any useful information.

Depends on D147689

Differential Revision: https://phabricator.services.mozilla.com/D147690
2022-06-02 11:58:18 +00:00
Mike Hommey c84e4eef26 Bug 1770894 - Update style to uluru 3.0. r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D147477
2022-05-31 22:05:05 +00:00
Mike Hommey 82584b1b75 Bug 1770894 - Update style to arrayvec 0.7. r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D147476
2022-05-31 22:05:04 +00:00
Mike Hommey d24426da1a Bug 1770894 - Update phf to 0.10. r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D147378
2022-05-31 22:05:02 +00:00
Mike Hommey 2b227894ee Bug 1771993 - Fix warnings about whitelist/blocklist functions being deprecated in bindgen 0.59. r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D147695
2022-05-31 21:40:29 +00:00
Emilio Cobos Álvarez f9b1d27b17 Bug 1771792 - Remove some dead vibrancy code. r=mstange
Drive-by cleanup.

Differential Revision: https://phabricator.services.mozilla.com/D147698
2022-05-31 10:43:29 +00:00
Emilio Cobos Álvarez 899b2b6d55 Bug 1770829 - Improve Percentage -> LengthPercentage conversion. r=barret
This doesn't change behavior because we only use them for images that
have no clamping.

Depends on D147008

Differential Revision: https://phabricator.services.mozilla.com/D147511
2022-05-31 08:33:50 +00:00
Emilio Cobos Álvarez 5e23244d4e Bug 1770616 - Do hue interpolations in degrees rather than radians. r=barret
This gives us a bit more precision.

Differential Revision: https://phabricator.services.mozilla.com/D147007
2022-05-31 08:33:49 +00:00
Emilio Cobos Álvarez 24b1154a40 Bug 1770616 - Fix hue adjustment to match the spec. r=barret
The value to sum is tau, not pi. This was caught by some tests, see
https://drafts.csswg.org/css-color/#shorter

Differential Revision: https://phabricator.services.mozilla.com/D147006
2022-05-31 08:33:48 +00:00
Emilio Cobos Álvarez db07ccc495 Bug 1770616 - Fix color-mix() percentage normalization. r=barret
Differential Revision: https://phabricator.services.mozilla.com/D147005
2022-05-31 08:33:48 +00:00
Emilio Cobos Álvarez e38118b831 Bug 1770616 - Implement more color-mix() color-spaces. r=barret
We had code to convert between these and the latest draft supports them so...

Differential Revision: https://phabricator.services.mozilla.com/D147004
2022-05-31 08:33:48 +00:00
Emilio Cobos Álvarez 817ea22aaf Bug 1770616 - Make the color interpolation code more generic. r=barret
It's really piece-wise premultiplied interpolation, with a special-case
for hue, so centralize the implementation.

Differential Revision: https://phabricator.services.mozilla.com/D147003
2022-05-31 08:33:47 +00:00
Emilio Cobos Álvarez 711d458368 Bug 1770616 - Update color-mix() syntax to match the current spec. r=barret
Test expectation updates for this in the latest patch of the bug.

Differential Revision: https://phabricator.services.mozilla.com/D147002
2022-05-31 08:33:47 +00:00
Hiroyuki Ikezoe 43bb9dc340 Bug 1312165 - Parse scroll-snap-stop style and propagate it to APZ side. r=emilio,botond
Depends on D146147

Differential Revision: https://phabricator.services.mozilla.com/D145850
2022-05-31 00:45:11 +00:00
criss 9933879ba5 Backed out changeset 68b233bf0519 (bug 1771792) for causing xpcshell failures on test_css-properties-db.js . CLOSED TREE 2022-05-31 02:06:55 +03:00
Emilio Cobos Álvarez 22ec54e75f Bug 1771792 - Remove some dead vibrancy code. r=mstange
Drive-by cleanup.

Differential Revision: https://phabricator.services.mozilla.com/D147698
2022-05-30 22:17:11 +00:00
Cosmin Sabou d3d37bf987 Backed out 4 changesets (bug 1770894) for causing build bustages.
Backed out changeset d4bd20e7ac74 (bug 1770894)
Backed out changeset ae6ffff33128 (bug 1770894)
Backed out changeset 2e4f492a8222 (bug 1770894)
Backed out changeset 13111f4c114a (bug 1770894)
2022-05-31 01:18:01 +03:00
Mike Hommey 999dd5b3ae Bug 1770894 - Update phf to 0.10. r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D147378
2022-05-30 21:37:37 +00:00
Mike Hommey 7b06b12d90 Bug 1770894 - Update in-tree crates to bindgen 0.59. r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D147221
2022-05-30 21:37:31 +00:00
Emilio Cobos Álvarez 1c2f2f9e15 Bug 1771764 - Remove 'static bound for ToShmem for Arc/ThinArc. r=dshin,layout-reviewers
It was only needed so that we could assert with TypeId::of::<T> that we
don't have duplicate values except for an exception.

Instead, fix the exception and remove the bound.

Differential Revision: https://phabricator.services.mozilla.com/D147669
2022-05-30 19:07:27 +00:00
Emilio Cobos Álvarez f64de373aa Bug 1381071 - Cache computed styles objects display: none subtrees. r=boris
This reuses our existing undisplayed style generation, but in a
per-document rather than per-nsComputedDOMStyle object, which means that
we can avoid re-resolving styles of elements in display: none subtrees
much more often.

This brings the test-case in the bug to par with other browsers or
better, and is much simpler than the initial approach I tried back in
the day.

Differential Revision: https://phabricator.services.mozilla.com/D147547
2022-05-30 11:08:15 +00:00
Emilio Cobos Álvarez 8cd9847ba9 Bug 1771151 - Make modal dialog code more generic, and make it apply to fullscreen too behind a pref. r=edgar
For now, don't turn it on by default yet, because I want to wait for
more discussion in https://github.com/w3c/csswg-drafts/issues/6965 and
so on. But I think the code is simple enough to land this.

Differential Revision: https://phabricator.services.mozilla.com/D147295
2022-05-30 11:06:06 +00:00
Oriol Brufau 4ccb54a537 Bug 1763828 - Change order of container shorthand. r=emilio
Since the initial value of container-type is an open issue [1],
I'm leaving that as-is for now.

[1] https://github.com/w3c/csswg-drafts/issues/7202

Differential Revision: https://phabricator.services.mozilla.com/D147338
2022-05-27 09:47:28 +00:00
Emilio Cobos Álvarez 99908fb968 Bug 1769512 - Implement overflow-clip-margin: <length>. r=jwatt
Differential Revision: https://phabricator.services.mozilla.com/D146432
2022-05-23 07:21:43 +00:00
Emilio Cobos Álvarez 0076bed412 Bug 1770532 - Ensure options in listbox selects are not stacking contexts by default. r=dholbert
We could have a different property or something but this seems
reasonable as well probably.

Differential Revision: https://phabricator.services.mozilla.com/D146994
2022-05-21 17:23:24 +00:00
Emilio Cobos Álvarez 1b778f1333 Bug 1769612 - More container queries plumbing. r=boris
Provide container information in computed::Context and use it to resolve
the container queries.

This still fails a lot of tests because we are not ensuring that layout
is up-to-date when we style the container descendants, but that's
expected.

Differential Revision: https://phabricator.services.mozilla.com/D146478
2022-05-20 09:59:39 +00:00
Marian-Vasile Laza 63d03ac9e2 Backed out changeset 99ab9844b58a (bug 1769612) for causing web-platform failures on container-size-invalidation-after-load.html. 2022-05-20 05:20:30 +03:00
Emilio Cobos Álvarez 2c70ec8d1f Bug 1769612 - More container queries plumbing. r=boris
Provide container information in computed::Context and use it to resolve
the container queries.

This still fails a lot of tests because we are not ensuring that layout
is up-to-date when we style the container descendants, but that's
expected.

Differential Revision: https://phabricator.services.mozilla.com/D146478
2022-05-20 00:49:44 +00:00
Narcis Beleuzu e38ec1329f Backed out changeset 8d386f8c684d (bug 1769612) for build bustages on applicable_declarations.rs 2022-05-20 02:15:44 +03:00
Emilio Cobos Álvarez 3e96c253ea Bug 1769612 - More container queries plumbing. r=boris
Provide container information in computed::Context and use it to resolve
the container queries.

This still fails a lot of tests because we are not ensuring that layout
is up-to-date when we style the container descendants, but that's
expected.

Differential Revision: https://phabricator.services.mozilla.com/D146478
2022-05-19 22:23:07 +00:00
Emilio Cobos Álvarez 46ca6e2712 Bug 1768285 - Clean up unused -moz-window-shadow values. r=jwatt
After bug 1768278 and bug 1767815 there's no more uses of the cliprounded value
in the tree (also it causes artifacts on HiDPI screens so we probably don't
want new usages).

The "sheet" value is unused, and the other values other than "default" and
"none" are only derived from "default", so they don't need to be exposed in the
style system.

Differential Revision: https://phabricator.services.mozilla.com/D145821
2022-05-17 23:20:48 +00:00
Autumn on Tape ba819ad54d Bug 1422312 - implement 'update' media feature r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D146338
2022-05-14 13:46:41 +00:00
Emilio Cobos Álvarez efb7960dba Bug 1768905 - Lint and 32-bit build fix.
MANUAL PUSH: Bustage fix CLOSED TREE
2022-05-11 21:43:39 +02:00
Emilio Cobos Álvarez 96360cdae3 Bug 1768905 - Move size of tests to compile-time tests in the style crate. r=dshin
Same reasoning as the previous commit.

Differential Revision: https://phabricator.services.mozilla.com/D146104
2022-05-11 19:02:58 +00:00
Emilio Cobos Álvarez 2cf5c869e6 Bug 1768905 - Convert specified value tests to compile-time tests. r=dshin
These were written at a time where std::mem::size_of wasn't a `const fn` in
Rust.

Now that it is, we can make these tests live in the style crate, and the build
not to compile if they fail.

Differential Revision: https://phabricator.services.mozilla.com/D146103
2022-05-11 19:02:57 +00:00
Emilio Cobos Álvarez 85f479d39b Bug 1767837 - Use debug_unreachable!() in matches_simple_selector. r=boris
This shrinks the function by avoiding generating rather noisy panic
code.

Depends on D145486

Differential Revision: https://phabricator.services.mozilla.com/D145487
2022-05-07 04:02:26 +00:00
Emilio Cobos Álvarez d8af45934c Bug 1767837 - Reorder some variants. r=boris
This doesn't make a difference, I was hoping it would allow us to remove the
special-casey code we have here:

  https://searchfox.org/mozilla-central/rev/997a56b018662e2940c99bbaf57a6ac9d1aa5422/servo/components/selectors/matching.rs#610-632

But it doesn't. Still I think it doesn't hurt tho, shouldn't change behavior.

Depends on D145485

Differential Revision: https://phabricator.services.mozilla.com/D145486
2022-05-07 04:02:25 +00:00
Emilio Cobos Álvarez 6ccaf80d38 Bug 1767837 - Simplify a bit hot selector-matching loop. r=boris
Note that element.clone() is just copying a couple pointers.

Have a single place where we compute the next element and check for linky-ness.
This saves a couple checks (very very minor win in the micro-benchmark I've
been looking at, but consistent).

Depends on D145484

Differential Revision: https://phabricator.services.mozilla.com/D145485
2022-05-06 23:52:23 +00:00