No reason these don't work on substrings.
Remove StripChars since it has an existing nsTSubstring version. Make
callers use rightly-typed characters for those.
Differential Revision: https://phabricator.services.mozilla.com/D145864
For both files, we've been keeping around an extra copy in
toolkit/themes/shared/media/ with 1-2 CSS rules related to presentation.
This was probably to allow XUL-style extensions and themes to override the
presentation, back when we supported that form of extension. But there's not a
good reason to have this separation anymore, so let's simplify and combine the
files of the same name.
This patch also removes one no-longer-esepcially-useful "N.B." comment (which
refers to a file that's now alongside the styles in question). This patch also
adds an explanatory comment to explain why we bother to set `color` for images
(which was initially not clear to me).
Differential Revision: https://phabricator.services.mozilla.com/D143395
This is mostly edge-casey, but see bug 1757156 for an example where it's
causing some issues (granted, they could use `href="#"` or something
instead of an empty href).
It feels weird if a link looks like a link (because the CSS definition
of a link matches, which is "has an href") but then mostly doesn't
behave as a link.
We can't navigate anywhere if we don't have a valid URI but maybe JS
handles the relevant events as in bug 1757156.
Use the CSS definition (has href) since that's interoperable across
browsers. This should also make some stuff much faster (since checking
'is link' is now just a bit check instead of a virtual call).
(Awaiting try results, if no tests need adjustments then I need to write
some)
Differential Revision: https://phabricator.services.mozilla.com/D142107
In particular, gather telemetry to evaluate the impact of unlabeled UTF-8
and how detector-triggered reloads would change if ASCII-only at initial
guess was treated as UTF-8.
Differential Revision: https://phabricator.services.mozilla.com/D140818
We have similar code for range inputs. This matches Blink (but not
WebKit), but I think it's a better default.
The spec seems to leave this up to UAs, so for now landing a
moz-specific WPT. Should be trivial to upstream if we want.
Depends on D141705
Differential Revision: https://phabricator.services.mozilla.com/D141706
OffscreenCanvasDisplayHelper may call back into HTMLCanvasElement after
it has been unlinked and violate our assumption that
HTMLCanvasElement::InvalidateCanvasPlaceholder is only called when we
have an OffscreenCanvas member. This patch makes it so that we clear the
relevant references during unlinking so that we don't make this mistake.
Differential Revision: https://phabricator.services.mozilla.com/D139380
This patch ensures we return an empty surface as per the spec when
the OffscreenCanvas passed into CreatePattern and DrawImage has no
context bound to it.
Differential Revision: https://phabricator.services.mozilla.com/D139127
This patch removes more main thread dependencies from the content side
of WebGPU. Instead of issuing a resource update for an external image,
we now use an async image pipeline in conjunction with
CompositableInProcessManager from part 1. This allows us to update the
HTMLCanvasElement bound to the WebGPU device without having to go
through the main thread, or even the content process after the swap
chain update / readback has been requested.
Differential Revision: https://phabricator.services.mozilla.com/D138887
This patch removes more main thread dependencies from the content side
of WebGPU. Instead of issuing a resource update for an external image,
we now use an async image pipeline in conjunction with
CompositableInProcessManager from part 1. This allows us to update the
HTMLCanvasElement bound to the WebGPU device without having to go
through the main thread, or even the content process after the swap
chain update / readback has been requested.
Differential Revision: https://phabricator.services.mozilla.com/D138887
We switch the open state storage to the element rather than the frame,
to be able to preserve it across reframes.
The code is loosely based on nsHideViewer in nsSubDocument.cpp, but it's
simpler because we don't need to do restoration shenanigans.
Differential Revision: https://phabricator.services.mozilla.com/D138689