It could lead to a ref-cycle leak if it was added as listener to a
MediaStreamTrack but the underlying track in the graph was never created, so
that the TracksCreatedListener never received NotifyOutput or NotifyRemoved
events.
Differential Revision: https://phabricator.services.mozilla.com/D39658
--HG--
extra : moz-landing-system : lando
This is inherently large, because modifying these bits of DOMMediaStream and
MediaStreamTrack affects all consumers and producers of all DOMMediaStreams and
MediaStreamTracks.
Things are generally much simpler now.
Producers of tracks now create a MediaStream in the graph, add it to a
MediaStreamTrackSource subclass that takes ownership of it, and add the source
to a MediaStreamTrack. Should the producer need a DOMMediaStream it is now much
simpler to create as the only thing needed is the current window. The stream is
a rather simple wrapper around an array of MediaStreamTracks.
HTMLMediaElement is still not as straight forward as other consumers since it
consumes the DOMMediaStream directly, as opposed to a set of tracks.
The new MediaStreamRenderer helper class helps bridge the gap between this fact
and the new track-based MediaStreamGraph interface, as it needs to juggle
registering multiple audio tracks for audio output. This hooks into existing
HTMLMediaElement logic and brings a welcome simplification to all the glue
previously needed there.
Differential Revision: https://phabricator.services.mozilla.com/D37934
--HG--
extra : moz-landing-system : lando
This ensures all clones of the original track also receives the new muted state.
Differential Revision: https://phabricator.services.mozilla.com/D37933
--HG--
extra : moz-landing-system : lando
Normally a track in mUpdateTracks is cleared by ExtractPendingInput, when that
track's ending is processed. However, if the SourceMediaStream is destroyed
before an ended track is processed, the track including it's buffered segment
in mUpdateTracks will leak until the SourceMediaStream is destroyed.
This might not be until late XPCOM Shutdown when the cycle collector shuts down,
which is too late to release graphics resources.
Depends on D37931
Differential Revision: https://phabricator.services.mozilla.com/D37932
--HG--
extra : moz-landing-system : lando
A legit case that fails this assert is:
- CloseAudioInput() on main thread for last non-webaudio MediaStream
- AudioContext closes on main thread
- CloseAudioInputImpl() on graph thread sets next driver to an output-only audio
driver since there are AudioNodeStreams still present
- AudioContext's Close operation is applied on graph thread, first all
AudioNodeStreams are suspended, making the graph consider itself as having no
audio tracks present. Then we check the next driver, which is an audio driver
per above. This fails the assert.
Differential Revision: https://phabricator.services.mozilla.com/D37931
--HG--
extra : moz-landing-system : lando
So that paint doesn't reenter on layout, or mess with incomplete frame trees, or
what not.
I just early-returned rather than only skipping the PaintWhileInterruptingJS
call because I don't think we should be running untrusted scripts in the first
place when IsSafeToRunScript() is false.
Differential Revision: https://phabricator.services.mozilla.com/D39913
--HG--
extra : moz-landing-system : lando
Writing disabled: if foo was a common mistake. The easiest fix is just to
require that 'if ' at the start of a string is quoted (one could also
fix this by interpreting these as real conditions, but that would be
more involved, and this fixes the immediate problem of invalid metadata).
Depends on D4952
Differential Revision: https://phabricator.services.mozilla.com/D4953
--HG--
extra : moz-landing-system : lando
This fixes the cases where we had an if condition on the same line as
as a key, which ends up with the condition being treated as a string.
Differential Revision: https://phabricator.services.mozilla.com/D4952
--HG--
extra : moz-landing-system : lando
See https://github.com/whatwg/html/issues/4810.
I accidentally changed its behavior in bug 1547985 due to an embarrassing typo.
Turns out that my typo made us follow the spec, but the spec is not what we or
anybody else implemented. Fun times. I added a test accounting for the proposed
spec change.
There's a different divergence between what does abscenter map to. Other
browsers don't map `abscenter` at all, looks like, but it's in the spec.
We may want to remove it, but for now I've left it in the test.
Differential Revision: https://phabricator.services.mozilla.com/D39928
--HG--
extra : moz-landing-system : lando
Automatic update from web-platform-tests
Update webxr_test_asserts and align xr layout_tests usage of asserts
Updates webxr_test_asserts with chromium's more verbose asserts for
easier debugging of tests, and removes the asserts from xr-test-utils
so that all asserts can be referenced from webxr_test_asserts.
Bug: 985156
Change-Id: Ie8d2ca70dd18a7e1759fe2b4d83b02076fcf91c0
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1715916
Commit-Queue: Alexander Cooper <alcooper@chromium.org>
Auto-Submit: Alexander Cooper <alcooper@chromium.org>
Reviewed-by: Klaus Weidner <klausw@chromium.org>
Cr-Commit-Position: refs/heads/master@{#680180}
--
wpt-commits: b94e0af56342652cf059d085758b0a229f3a38fb
wpt-pr: 18012
Automatic update from web-platform-tests
Fixing tranferFromimageBitmap-toBlob-offscreen.html to not be flaky
Replacing the getElementById by the creation of a new element to ensure
that the test will not be flaky.
Changing also the name of the function to be coherent with the test itself.
Bug: 978554
Change-Id: I8848b18f6d7f6201cce57069c5f4047d4d2f61e2
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1693189
Commit-Queue: Juanmi Huertas <juanmihd@chromium.org>
Reviewed-by: Fernando Serboncini <fserb@chromium.org>
Cr-Commit-Position: refs/heads/master@{#677456}
--
Fix promises in tranferFromImageBitmap-ToBlob-offscreen.html
The test previously used promises incorrectly:
testTransferFromImageBitmapToBlobOffscreen did not return the promise
produced by convertToBlob up to promise_test, which caused the assertion
(inside testCanvas) to flakiy escape promise_test. In addition, the test
did not wait for pngImage to load before drawing it to canvas.
This change also fixes the name of the test to be more accurate
(transferToBlob -> convertToBlob).
--
wpt-commits: 88a0c99744a4941af3907dfbb3853e3c23b00f04, 811dc186a0946a67e2b1ae59c0e92ccfeb69371d
wpt-pr: 17747
Automatic update from web-platform-tests
[LargestContentfulPaint] Add type to supportedEntryTypes
This CL adds 'largest-contentful-paint' to PerformanceObserver's
supportedEntryTypes, and adds a test. It also fixes a typo in the
LayoutShift supportedEntryTypes test title.
Bug: 965505
Change-Id: I6954f8abbdf27640413d790e05ff72aa945a248b
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1713295
Commit-Queue: Nicolás Peña Moreno <npm@chromium.org>
Reviewed-by: Steve Kobes <skobes@chromium.org>
Cr-Commit-Position: refs/heads/master@{#680131}
--
wpt-commits: 2e53b93235999c9c9272859c2b2beadb96ef1f09
wpt-pr: 17975
Automatic update from web-platform-tests
Fix WebGLLayer test expectations
The xrWebGLLayer tests didn't have their expectations wrapped in t.step
so their failures were reported as timeouts, rather than the actual
error.
xrWebGLLayer_viewports expected the device init viewport to match the
output viewport, which is not a specced behavior, and contradicts the
webxr-test-api spec which calls this out as unsupported, so that part
has also been reverted.
Bug: 986672
Change-Id: I23713956f6b0bd3d432f0e6e6fdc9d015d509099
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1715237
Commit-Queue: Alexander Cooper <alcooper@chromium.org>
Commit-Queue: Klaus Weidner <klausw@chromium.org>
Reviewed-by: Klaus Weidner <klausw@chromium.org>
Auto-Submit: Alexander Cooper <alcooper@chromium.org>
Cr-Commit-Position: refs/heads/master@{#680125}
--
wpt-commits: 66cf52a5ffde8f409ebef4052ec0d1f30383875d
wpt-pr: 18004
Automatic update from web-platform-tests
[ElementTiming] Replace responseEnd with loadTime
This CL replaces responseEnd with loadTime in ElementTiming. Before,
responseEnd would be used and would be problematic for memory cached
images and for inline images (data scheme). We change it to loadTime,
the time at which LayoutObject::ImageNotifyFinished is called. This is
the same time as when LargestContentfulPaint computes loadTime. As they
are both under runtime flags and the hooks are not unified, for
simplicity we compute the timestamp again. This will not be too
expensive for ElementTiming, as the timestamp is gated on the existence
of the elementtiming attribute.
To store the loadTime, we change images_notified_ to be a HashMap which
now stores the timestamp corresponding to loadTime and whether the image
has painted (after being loaded).
Bug: 982046, 879270
Change-Id: I69da42c9250cc36c567df5da285ef1a9a357b554
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1710840
Commit-Queue: Nicolás Peña Moreno <npm@chromium.org>
Reviewed-by: Steve Kobes <skobes@chromium.org>
Cr-Commit-Position: refs/heads/master@{#680117}
--
wpt-commits: 5275930d8392750a8d16934abc6c3f8f9802bcd6
wpt-pr: 17950
Automatic update from web-platform-tests
[LargestContentfulPaint] Replace responseEnd with loadTime
This CL replaces responseEnd with loadTime. Before, responseEnd would be
used and would be problematic for memory cached images. We change it to
loadTime, the time at which LayoutObject::ImageNotifyFinished is called.
This time has the advantage of being independent of the memory cache and
being after the image has been appended to the DOM, as shown by a test.
To implement loadTime, we use a new HashMap. This HashMap populates the
timestamps that will be used in ImageRecords. We cannot use the existing
data structures because this happens before we know whether the image
will be added to the set of visible or invisible images, etc.
Bug: 982046, 965505
Change-Id: I50d4f304a35b60409c58c54a5bd912e7d15825e9
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1710682
Commit-Queue: Nicolás Peña Moreno <npm@chromium.org>
Reviewed-by: Steve Kobes <skobes@chromium.org>
Cr-Commit-Position: refs/heads/master@{#680096}
--
wpt-commits: 09143c197281e64651bad6e92a9397fd7eff084a
wpt-pr: 17945
Automatic update from web-platform-tests
[LayoutNG] Remove shrink-to-fit optimization.
For NG types this isn't needed anymore. The NG types now use:
CalculateSizeBasedLayoutCacheStatusWithGeometry
Which determines the size of a fragment ahead of time, and applies the
same optimization.
The only thing that we now miss, is things which are sized shrink-to-fit
which use legacy layout.
We couldn't apply this optimization to shrink-to-fit tables, as they
may have %-based inline-sized children which affect their (final) inline
size.
Bug: 984642
Change-Id: I0d0b584f31947bb674f4e7e5d88d7af6cf5d9d98
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1662535
Commit-Queue: Ian Kilpatrick <ikilpatrick@chromium.org>
Reviewed-by: Emil A Eklund <eae@chromium.org>
Reviewed-by: Christian Biesinger <cbiesinger@chromium.org>
Cr-Commit-Position: refs/heads/master@{#680095}
--
wpt-commits: f77e198cb7d4d59be5ceebd36738333c3d1930fd
wpt-pr: 18005
Automatic update from web-platform-tests
Add toast type attribute support with IDL property and default styles
This change adds the toast type attribute and property
according to the PR on the toast explainer here:
https://github.com/jackbsteinberg/std-toast/pull/49
There is still work TODO on implementing this PR,
w.r.t the showToast type option, a11y behavior for warning / error,
and default features for those types (Infinity duration, closebutton, etc)
Additionally, a follow-up CL will come out to reconfigure the current
reflection tests for type and open to use established reflection test
methodology
(ex: https://cs.chromium.org/chromium/src/third_party/blink/web_tests/wpt_internal/std-switch/tentative/form-associated-basic.js)
Bug: 972945
Change-Id: I58c7079dc4f748928eea44103dece835e549986e
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1708313
Commit-Queue: Jack Steinberg <jacksteinberg@chromium.org>
Reviewed-by: Fergal Daly <fergal@chromium.org>
Cr-Commit-Position: refs/heads/master@{#680073}
--
wpt-commits: 109a7d171d08bceb61dce865576de3c15f61c16c
wpt-pr: 17923
Automatic update from web-platform-tests
Fixing rendering of backdrop-filter with opacity
Prior to this CL, a node that contained both opacity and backdrop-filter
would sometimes not be properly rendered. The opacity was, in some cases,
applied as if there was an opaque black background behind the filter
region, rather than compositing the filtered image into the background
with the specified opacity. This CL changes the way opacity is applied,
moving it to the paint of the final filtered image, which fixes the
problem.
Bug: 983252
Change-Id: I9fae88c8f7b1c950d5616e1c9eeaaa664bab649a
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1707457
Reviewed-by: Eric Karl <ericrk@chromium.org>
Commit-Queue: Mason Freed <masonfreed@chromium.org>
Cr-Commit-Position: refs/heads/master@{#680076}
--
wpt-commits: abdea75716f7949ce2e3060e2926beccd8ee8003
wpt-pr: 17911
Automatic update from web-platform-tests
[css-properties-values-api] CSS.supports should ignore syntax after all.
According to a recent spec change, the syntax of a registered custom
property must be ignored until computed-value time. This means that
CSS.supports must treat all custom properties as unregistered.
This effectively reverts 9646ae2d0269da525804f2d60c6c0380e754bd3f (except
the test).
Bug: 641877
Change-Id: I6d24fc23534636b88167121b73b28455f563d501
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1713508
Reviewed-by: Rune Lillesveen <futhark@chromium.org>
Commit-Queue: Anders Hartvoll Ruud <andruud@chromium.org>
Cr-Commit-Position: refs/heads/master@{#679986}
--
wpt-commits: 151e5cc98d40a21d6f1202a2e5fc8d464722f475
wpt-pr: 17998
Automatic update from web-platform-tests
Fixed several errors in the tests' title. (#17999)
--
wpt-commits: 82fed3e767931a475eba1e852be081cd9f685a65
wpt-pr: 17999
Automatic update from web-platform-tests
[html] Use documented `nonexistent` instead of foo (#17979)
* [html] Use documented `nonexistent` instead of foo
The idlharness test needs a dummy WebSocket object with a failed
connection. This should be done using the documented `nonexistent`
subdomain instead of `foo` which could resolve successfully in certain
network environments.
Fixes#17977.
* Revise to use get-host-info.sub.js
--
wpt-commits: ff8486db5a8f56f13b760a27a0e13a3fe9710d1f
wpt-pr: 17979