No behavior change, just moving and renaming files.
The code in the "queries" module will be shared between @media and
@container.
@media has some other code that container queries doesn't need like
MediaList / MediaType / etc. That remains in the media_queries module.
Differential Revision: https://phabricator.services.mozilla.com/D144435
Make the representation the same between Gecko and Servo code. This will
enable further clean-ups in the future.
Make serialization be correct, serializing as identifier unless it's an
invalid one (in which case we serialize as a string).
This changes our stringification behavior in the specified style, but
now it will match the computed style and be more correct over-all.
Differential Revision: https://phabricator.services.mozilla.com/D144473
The brush_yuv_image slow path expected a YUV color matrix that applies scaling,
whereas we set up a matrix for SWGL that had no scaling to support the fast path.
To work around the fact that both paths have different scaling requirements, we
pass the matrix with scaling down to the fast path and undo the scaling later
when constructing SWGL's internal YUVMatrix from it. This allows both paths to
just use the same matrix and avoids the footgun.
Differential Revision: https://phabricator.services.mozilla.com/D144479
This patch adds support for including the canvas contents in Firefox
Screenshots for Canvas 2D, WebGL and WebGPU. It is already working for
context's created through an OffscreenCanvas, but we failed to hook up
the main thread path after refactoring in previous bugs.
Differential Revision: https://phabricator.services.mozilla.com/D144310
This patch hooks up the improved CanvasManagerChild::GetSnapshot method
to the WebGPU canvas context object in order to do readbacks for various
DOM facing methods such as ConvertToBlob and for Firefox Screenshots.
Differential Revision: https://phabricator.services.mozilla.com/D144309
This reworks the CanvasManagerChild::GetSnapshot method to work with
WebGPU. This will allow it to be called for a WebGPU context from any
thread, which is useful for screenshots.
Differential Revision: https://phabricator.services.mozilla.com/D144308
We only use the value to modify shouldSubtractDynamicToolbar and we only use that with a dynamic toolbar.
This saves us some time and also prevents a circular dependency when reflowing a scroll frame. nsHTMLScrollFrame::TryLayout calls nsLayoutUtils::CalculateCompositionSizeForFrame
https://searchfox.org/mozilla-central/rev/6da1ebe13b260efabd88eb98dec5fa8ee65987b2/layout/generic/nsGfxScrollFrame.cpp#616
and then nsLayoutUtils::UpdateCompositionBoundsForRCDRSF calls GetScrolledRect, but reflow can determine the scrolled rect (presence/absence of scrollbars affect it for example).
But this also prevents us from hitting the warning of bug 1695139 in the case of a google search results page as one example, because we are getting the scrolled rect while we might be in an inconsistent state during reflow.
Differential Revision: https://phabricator.services.mozilla.com/D144423
This gives us better correctness for 10-bit vp9 reftests. In the WPTs, we
turn off some tests on macos because of the difficulty that our
screenshots have in analyzing srgb image data. It seems to consistently
report 191,255,191,73 when we are expecting 255,0,0,255.
Differential Revision: https://phabricator.services.mozilla.com/D144228
This change ensures that macOS will correctly detect the surface as a video
and use an HDR-capable display layer. Unfortunately, it invokes a slower code
path for this case. Bug 1765388 may restore this fast path for HDR video.
Differential Revision: https://phabricator.services.mozilla.com/D144039
For supporting Thunderbird's l10n-cross-channel operations. A Thunderbird
specific mach command will pass the config function to cross_channel()
via _mach_context.commands.dispatch.
Differential Revision: https://phabricator.services.mozilla.com/D131976
Normally, we treat the body as the DOM node for a DocAccessible.
However, a click listener can be added to the root element; e.g. the html element.
We now treat a click listener added to the root element the same as if one were added to the body.
This required a change to nsAccessibilityService to use the DocAccessible when click listeners change for the root element so a cache update is pushed.
This change was made for the body also, since we weren't pushing a cache update for click listener changes on the body either.
Differential Revision: https://phabricator.services.mozilla.com/D144278
Previously, we supported an action on text leaf and image accessibles if an ancestor was a link or was clickable.
However, we didn't support it on any other kind of descendant, nor could clients differentiate between a click handler on the descendant itself vs an action propagated because of an ancestor.
In addition, the click was performed on the ancestor element itself, rather than bubbling up to the ancestor.
This was probably never a real problem given the limited scope, but it meant that the actual event target was lost.
This has been replaced by a "click ancestor" action supported on all descendants of ancestors providing an action.
The click is dispatched to the descendant and bubbles up to the ancestor.
Aside from consistency and the ability to differentiate the action, this allows clients to stop relying on simulating clicks themselves to directly target a descendant.
This avoids problems caused by obscured web elements, obscured browser windows and other weird screen coordinate issues.
It thus fixes several problems reported by NVDA screen reader users.
Differential Revision: https://phabricator.services.mozilla.com/D144252
The brush_yuv_image slow path expected a YUV color matrix that applies scaling,
whereas we set up a matrix for SWGL that had no scaling to support the fast path.
To work around the fact that both paths have different scaling requirements, we
pass the matrix with scaling down to the fast path and undo the scaling later
when constructing SWGL's internal YUVMatrix from it. This allows both paths to
just use the same matrix and avoids the footgun.
Differential Revision: https://phabricator.services.mozilla.com/D144479
The transfer function value is only used for BT2020 colorspace videos. We
capture the transfer function when the decoder is created, because it is
not updated per-frame in the VPX bitstream. If a video changes colorspace,
we keep the transfer function value in case it returns to using the BT2020
colorspace.
Differential Revision: https://phabricator.services.mozilla.com/D143665
When there are a large number of sibling backdrop-filter primitives
present, the existing naive recursive traversals to assign the
`render_on` and `free_after` passes hit pathological cases. In
the test case for this bug, a debug build takes 12+ seconds to
complete on my development machine.
Instead, switch to a topological sort for `render_on` assignment,
and use a non-recursive traversal to set `free_after` (which relies
on having the passes in-order from the topo sort to avoid recursion).
Differential Revision: https://phabricator.services.mozilla.com/D144359