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

90198 Коммитов

Автор SHA1 Сообщение Дата
Sebastian Streich 52a6d76d90 Bug 1376310 - Ensure a nsIDocShell after checking IsOriginPotentiallyTrustworthy r=ckerschb
Differential Revision: https://phabricator.services.mozilla.com/D60742

--HG--
extra : moz-landing-system : lando
2020-02-10 14:51:10 +00:00
Boris Zbarsky 05327f8a52 Bug 1613978. Allow passing u"...", not just nsAStrings, to templated ThrowType/RangeError. r=peterv
Differential Revision: https://phabricator.services.mozilla.com/D62061

--HG--
extra : moz-landing-system : lando
2020-02-10 13:08:48 +00:00
Tetsuharu OHZEKI 9934259eac Bug 1612483 - Remove mozilla::dom::TabContext::IsMozBrowser(). r=bzbarsky
Now, this method returns simply the result of of `IsMozBrowserElement()`.

In the old days, We used to have IsMozBrowserElement and IsMozBrowserOrApp,
where the latter was true if we had a mozapp or mozbrowser.
But with b2g removed, the app thing went away.

`IsMozBrowser()` is less used than `IsMozBrowserElement()`.

I think the former should be replaced by the later one.

Differential Revision: https://phabricator.services.mozilla.com/D61699

--HG--
extra : moz-landing-system : lando
2020-02-05 16:27:49 +00:00
Paul Adenot 678d895cf5 Bug 1566312 - Perform microtask checkpoints in between the computation of blocks. r=karlt
Differential Revision: https://phabricator.services.mozilla.com/D61727

--HG--
extra : moz-landing-system : lando
2020-02-10 08:50:58 +00:00
Mirko Brodesser 067c1b95c6 Bug 1613378: part 5) Decouple `UserSelectRangesToAdd` from `Selection` class. r=smaug
Depends on D62037

Differential Revision: https://phabricator.services.mozilla.com/D62038

--HG--
extra : moz-landing-system : lando
2020-02-07 16:16:36 +00:00
Mirko Brodesser ce8bf8cde1 Bug 1613378: part 4) Declare some methods in `nsFrameSelection` static. r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D62037

--HG--
extra : moz-landing-system : lando
2020-02-07 16:13:27 +00:00
Boris Zbarsky 1852a29c3b Use %g, not %f, for our error reporting so unnecessary trailing zeros are not output. No bug. r=birtles
Differential Revision: https://phabricator.services.mozilla.com/D62062

--HG--
extra : moz-landing-system : lando
2020-02-10 01:35:00 +00:00
Brad Werth 69e6a4776b Bug 1523853 Part 3: Further relax the mousewheel test to not care about the ending scroll values. r=kats
This is being done to reduce the intermittent failures we see in this test.
There are other non-intermittent tests that measure the specific number of
pixels traveled by mousewheel events. The focus of this test seems to be
"Ensure that mousewheel scrolling and zooming are mutually exclusive" and
this change maintains that.

Depends on D62067

Differential Revision: https://phabricator.services.mozilla.com/D62130

--HG--
extra : moz-landing-system : lando
2020-02-08 20:15:16 +00:00
Boris Zbarsky d5a8ae31d4 Bug 1614173. Stop using NS_ERROR_DOM_TYPE_ERR in ChromeNodeList. r=baku
Differential Revision: https://phabricator.services.mozilla.com/D62156

--HG--
extra : moz-landing-system : lando
2020-02-09 14:51:57 +00:00
Boris Zbarsky 4472ba99ca Bug 1614165 part 1. Improve error messages for SVG text. r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D62154

--HG--
extra : moz-landing-system : lando
2020-02-09 02:15:32 +00:00
Ting-Yu Lin f42b7fab77 Bug 1614024 - Re-add fuzzy annotation on Android for bug453105.
The annotation was removed in bug 1613380, but it happens again. Let's
add it back.

Differential Revision: https://phabricator.services.mozilla.com/D62117

--HG--
extra : moz-landing-system : lando
2020-02-07 22:16:08 +00:00
Emilio Cobos Álvarez 374cabd6e7 Bug 1606628 - Remove nsStyleImageRequest. r=tnikkel,heycam
This removes nsStyleImageRequest by moving the load state to LoadData instead
(where other lazy state like the resolved URL and load id lives).

That way we can use cbindgen for more stuff (there's no blocker for using it for
all images now), and we can undo the image tracking shenanigans that I had to do
in bug 1605803 in nsImageFrame.

This removes the mDocGroup member because well, there's no real upside of that
now that quantum DOM is not a thing.

It also removes the static clones of the image requests, and the need for each
computed value instance to have its own request. These were needed because we
needed the image loader for the particular document to observe the image
changes. But we were also tracking the request -> loader for other purposes.
Instead, Now all the images get loaded with GlobalImageObserver as a listener,
which looks in the image map and forwards the notification to all the interested
loaders instead dynamically.

The style value is only responsible to load the image, and no longer tracks /
locks it. Instead, the loader does so, via the image tracker.

Differential Revision: https://phabricator.services.mozilla.com/D58519

--HG--
extra : moz-landing-system : lando
2020-02-07 20:36:34 +00:00
Jeff Gilbert 165c15a8f3 Bug 1613106 - Add missing context loss check. r=lsalzman
The call to InitializeCanvasRenderer earlier in the function can lose
the context.

Differential Revision: https://phabricator.services.mozilla.com/D62100

--HG--
extra : moz-landing-system : lando
2020-02-07 20:19:43 +00:00
Ting-Yu Lin c26c7aeb90 Bug 1613380 - Use FlexboxAxisTracker's main axis to initialize strut FlexItem's mMainAxis. r=dholbert
Annotate optiontext.html for Android as slightly fuzzy, to account for
reftest rebucketing fuzzy-failure fallout. It has 0 in the lower bound
of the fuzzy annotation because not every Android has this
fuzzy-failure.

Meanwhile, bug453105.html no longer fails due to reftest rebucketing, so
I remove its fuzzy annotation.

Differential Revision: https://phabricator.services.mozilla.com/D61877

--HG--
extra : moz-landing-system : lando
2020-02-07 18:53:28 +00:00
Brad Werth a547ad53da Bug 1523853 Part 2: Re-enable the mousewheel scroll/zoom test on Windows. r=kats
Differential Revision: https://phabricator.services.mozilla.com/D62067

--HG--
extra : moz-landing-system : lando
2020-02-07 18:46:27 +00:00
Andreea Pavel 217f810381 Backed out changeset 5a4eb6758bed (bug 1609916) for hazard bustages on a CLOSED TREE 2020-02-07 20:20:10 +02:00
Lars T Hansen ccea2f09db Bug 1609916 - Callback from SC to DOM on SAB cloning. r=luke
When structured clone reads a SAB and creates a new SAB object, or
when it serializes a SAB onto a channel, call a callback that lets the
embedder know.  The embedder can then adjust its policy.  Concretely,
we want to allow the browser to serialize threads in a process that
uses JS shared memory.

Note, for WebAssembly.Memory, reading and writing are delegated to the
cloning operations for SAB, so no special handling is needed.

Differential Revision: https://phabricator.services.mozilla.com/D61455

--HG--
extra : moz-landing-system : lando
2020-02-07 16:54:48 +00:00
Andrea Marchesini 3efc616139 Bug 1613909 - Enable shared-memory for SAP + postMessage() tests, r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D62036

--HG--
extra : moz-landing-system : lando
2020-02-07 16:08:05 +00:00
Daniel Varga 0d5be0b49c Backed out changeset 1dc5c3074b57 (bug 1609916) for causing spidermonkey bustage
CLOSED TREE
2020-02-07 18:35:30 +02:00
Lars T Hansen 390dff3ee2 Bug 1609916 - Callback from SC to DOM on SAB cloning. r=luke
When structured clone reads a SAB and creates a new SAB object, or
when it serializes a SAB onto a channel, call a callback that lets the
embedder know.  The embedder can then adjust its policy.  Concretely,
we want to allow the browser to serialize threads in a process that
uses JS shared memory.

Note, for WebAssembly.Memory, reading and writing are delegated to the
cloning operations for SAB, so no special handling is needed.

Differential Revision: https://phabricator.services.mozilla.com/D61455

--HG--
extra : moz-landing-system : lando
2020-02-07 15:42:37 +00:00
Jan Varga 4e80555e4f Bug 1608759 - Implement and use verifyStorage() function in all upgrade tests; r=dom-workers-and-storage-reviewers,ttung
The new verifyStorage() function takes current storage structure on disk and compares it with the expected structure. The expected structure is defined in JSON and consists of a per test package definition and a shared package definition. The shared package definition contains unknown files and directories which need to be ignored in all upgrade methods.
The new infrastructure for checking storage structure will be used later in other tests to verify handling of unknown or obsolete stuff for example during temporary storage initialization.

Differential Revision: https://phabricator.services.mozilla.com/D61450

--HG--
extra : moz-landing-system : lando
2020-02-07 15:32:26 +00:00
Jan Varga 6f4faaf11f Bug 1608759 - installPackage() shouldn't allow file overwrites by default; r=dom-workers-and-storage-reviewers,ttung
Differential Revision: https://phabricator.services.mozilla.com/D61449

--HG--
extra : moz-landing-system : lando
2020-02-07 15:29:24 +00:00
Daniel Varga 1c197e92da Backed out 2 changesets (bug 1608759) for causing lint failure
CLOSED TREE

Backed out changeset cb706e608d58 (bug 1608759)
Backed out changeset f2a08319ac10 (bug 1608759)

--HG--
extra : amend_source : 251fcc6d6304fe6a4ed240f6d1d409fc168f1c31
2020-02-07 17:23:36 +02:00
Jan Varga 469bf12cb7 Bug 1608759 - Implement and use verifyStorage() function in all upgrade tests; r=dom-workers-and-storage-reviewers,ttung
The new verifyStorage() function takes current storage structure on disk and compares it with the expected structure. The expected structure is defined in JSON and consists of a per test package definition and a shared package definition. The shared package definition contains unknown files and directories which need to be ignored in all upgrade methods.
The new infrastructure for checking storage structure will be used later in other tests to verify handling of unknown or obsolete stuff for example during temporary storage initialization.

Differential Revision: https://phabricator.services.mozilla.com/D61450

--HG--
extra : moz-landing-system : lando
2020-02-07 14:58:38 +00:00
Jan Varga fc5548f510 Bug 1608759 - installPackage() shouldn't allow file overwrites by default; r=dom-workers-and-storage-reviewers,ttung
Differential Revision: https://phabricator.services.mozilla.com/D61449

--HG--
extra : moz-landing-system : lando
2020-02-07 14:41:54 +00:00
Olli Pettay f49348082e Bug 1612431, it is enough to update existing browsing context name when changing iframe.name, r=kmag
This brings back some of the behavior we had before bug 1578628.

Differential Revision: https://phabricator.services.mozilla.com/D61637

--HG--
extra : moz-landing-system : lando
2020-02-06 18:44:05 +00:00
Thomas Dolezal 062c15357a Bug 1611733 - Bug 1611633 - convert ns style position defines to enum class. r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D61958

--HG--
extra : moz-landing-system : lando
2020-02-07 12:35:30 +00:00
Mike de Boer 7c59083d88 Bug 1613627 - Rename 'WifiGeo' to the more generic and appropriate 'NetworkGeo' inside the module. r=garvan
Depends on D50209

Differential Revision: https://phabricator.services.mozilla.com/D50210

--HG--
extra : moz-landing-system : lando
2020-02-06 14:50:38 +00:00
Mike de Boer 54e9a591b2 Bug 1613627 - Rename all 'geo.wifi' related preferences to match the 'geo.provider.' convention and move default values to all.js. r=garvan
Differential Revision: https://phabricator.services.mozilla.com/D50209

--HG--
extra : moz-landing-system : lando
2020-02-06 14:50:22 +00:00
Imanol Fernandez 71954016da Bug 1613712 - Pass a correct compositorConnection instead of null ptr in the GLScreenBuffer::CreateFactory call used to ensure that a not added to DOM canvas is ready for VR. r=jgilbert
Fix regression from the WebGL remoting client/host refactor.

Differential Revision: https://phabricator.services.mozilla.com/D61878

--HG--
extra : moz-landing-system : lando
2020-02-07 01:52:43 +00:00
Mirko Brodesser cc5ff82f69 Bug 1613378: part 3) Remove `Selection::GetTableCellLocationFromRange`'s dependency to `mFrameSelection` and declare it static. r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D61693

--HG--
extra : moz-landing-system : lando
2020-02-07 09:24:53 +00:00
Mirko Brodesser f3af81d6e9 Bug 1613378: part 1) Decouple `Selection::GetTableSelectionType` from `Selection` class. r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D61691

--HG--
extra : moz-landing-system : lando
2020-02-07 09:24:34 +00:00
Mirko Brodesser b58f8fa656 Bug 1611853: part 2) Add crashtest. r=smaug
Tests that selecting a contentEditable node with style `user-select:
none` via `execCommand` doesn't trigger an assertion.

Differential Revision: https://phabricator.services.mozilla.com/D61829

--HG--
extra : moz-landing-system : lando
2020-02-06 16:38:29 +00:00
Tom Tung 5666324739 Bug 1612307 - Fix a set of typos on interface mochitests; r=annevk
Differential Revision: https://phabricator.services.mozilla.com/D61579

--HG--
extra : moz-landing-system : lando
2020-02-07 07:37:33 +00:00
Jeff Gilbert b9a4e49ccf Bug 1611837 - Allow null `data` if `dataLen` is zero. r=lsalzman
Differential Revision: https://phabricator.services.mozilla.com/D61953

--HG--
extra : moz-landing-system : lando
2020-02-07 03:17:26 +00:00
Edgar Chen 7ab4025bf5 Bug 1613708 - Enable some disabled pointer event mochitests on Android; r=masayuki
Differential Revision: https://phabricator.services.mozilla.com/D61947

--HG--
extra : moz-landing-system : lando
2020-02-07 00:18:14 +00:00
Nika Layzell c56289e054 Bug 1557739 - Be more consistent with IPC Transport APIs, r=jld
Differential Revision: https://phabricator.services.mozilla.com/D60285

--HG--
extra : moz-landing-system : lando
2020-02-06 22:41:56 +00:00
Emilio Cobos Álvarez 873a349556 Bug 1611701 - Tweak NODE_IS_EDITABLE flag handling for NAC so that it works consistently for <input type=number>. r=bzbarsky,masayuki,whimboo
I thought this would fix <input type=number style="user-select: none">, but
turns out it doesn't.

<input type=number> doesn't have the editor root as a root of the anonymous
subtree, so the current hack wouldn't work, as the anon root wouldn't have the
editable flag. So tweak the code a bit to handle stuff in a simpler way than
setting the flags after the fact, and set the NAC-root flag earlier to avoid
the mOuterWrapper->AppendChildTo(root) call forgetting about root's flags.

I had to tweak one AccessibleCaret test, but that's because it uses <textarea>
with user-select: none, and our behavior there is not particularly sane. It just
happened to work because that test-case also had a bunch of contenteditable
elements, and we stop matching this rule:

  https://searchfox.org/mozilla-central/rev/220a3bd6063fcbe5ca50e88dcabdc7dee0aca448/layout/style/contenteditable.css#22

Because the anonymous div now properly matches :-moz-read-write, which made the
rule apply and the test work. See comment 4 of this bug.

I'll fix this stuff up and add some tests for our behavior here in bug 1611699.

I refactored the dragdrop tests to cover more input types, but I ended up not
being able to use them because they're dependent on the content.

Instead I added an extra test and changed the refactor so that it applies to
<input type=search>, as there's layout work going on in bug 558594, and it'd be
unfortunate to regress this there too.

Differential Revision: https://phabricator.services.mozilla.com/D61094

--HG--
extra : moz-landing-system : lando
2020-02-06 22:15:19 +00:00
Nika Layzell 9f47c9648c Bug 1611457 - Respect script blocker in JSWindowActor, r=bzbarsky
Differential Revision: https://phabricator.services.mozilla.com/D61354

--HG--
extra : moz-landing-system : lando
2020-02-04 18:16:07 +00:00
Nika Layzell 148a71bcbc Bug 1612724 - Part 2: Use NotifyWhenScriptSafe for MediaManager notifications, r=jib
Differential Revision: https://phabricator.services.mozilla.com/D61601

--HG--
extra : moz-landing-system : lando
2020-02-06 21:57:52 +00:00
Boris Zbarsky 1395be1f23 Bug 1613013 part 3. Annotate TypeErrors and RangeErrors from WebIDL implementations with the method they come from. r=peterv
Please review the changes to Errors.msg very carefully.  I caught a number of
mistakes there in self-review (e.g. not renumbering replacement markers
correctly when I added {0} to the beginnings of strings), and my confidence
that I caught them all is only middling.

A few lines (MSG_USELESS_SETTIMEOUT, MSG_TYPEDARRAY_IS_DETACHED,
MSG_NOT_SUBMIT_BUTTON) were removed from Errors.msg either because they were
already unused or because they either were single-user constant strings or
became such in the new setup and we could just use the string version of
ThrowTypeError.

Differential Revision: https://phabricator.services.mozilla.com/D61523

--HG--
extra : moz-landing-system : lando
2020-02-06 21:22:32 +00:00
Boris Zbarsky 09a1a6496e Bug 1613013 part 2. Change ThrowErrorMessage to be templated on the error number. r=peterv
This makes it easier to static_assert correct use.  It caught several bugs in
the next patch in this stack.

I had to disambiguate some calls to the templated ThrowDOMException that are
inside the binding_detail namespace, because otherwise they were trying to call
teh non-template function of the same name that's declared in binding_detail.

Differential Revision: https://phabricator.services.mozilla.com/D61522

--HG--
extra : moz-landing-system : lando
2020-02-06 20:40:36 +00:00
Boris Zbarsky 747a4d9f0a Bug 1613013 part 1. Annotate DOMExceptions from WebIDL implementations with the method they come from. r=peterv
This adds the name of the interface and method to the beginning of the exception
string when reporting the exception from Web IDL codegen, so it's clearer what
was called.

Some existing error messages are adjusted to not duplicate the information
about which method was called.

Differential Revision: https://phabricator.services.mozilla.com/D61521

--HG--
extra : moz-landing-system : lando
2020-02-06 21:16:10 +00:00
Mihai Alexandru Michis 823e8c21f1 Backed out changeset c9f4dd3ed78b (bug 1606628) for causing failures in ImageLoader.cpp
CLOSED TREE
2020-02-06 23:19:55 +02:00
Emilio Cobos Álvarez 77c6b3e983 Bug 1606628 - Remove nsStyleImageRequest. r=tnikkel,heycam
This removes nsStyleImageRequest by moving the load state to LoadData instead
(where other lazy state like the resolved URL and load id lives).

That way we can use cbindgen for more stuff (there's no blocker for using it for
all images now), and we can undo the image tracking shenanigans that I had to do
in bug 1605803 in nsImageFrame.

This removes the mDocGroup member because well, there's no real upside of that
now that quantum DOM is not a thing.

It also removes the static clones of the image requests, and the need for each
computed value instance to have its own request. These were needed because we
needed the image loader for the particular document to observe the image
changes. But we were also tracking the request -> loader for other purposes.
Instead, Now all the images get loaded with GlobalImageObserver as a listener,
which looks in the image map and forwards the notification to all the interested
loaders instead dynamically.

The style value is only responsible to load the image, and no longer tracks /
locks it. Instead, the loader does so, via the image tracker.

Differential Revision: https://phabricator.services.mozilla.com/D58519

--HG--
extra : moz-landing-system : lando
2020-02-06 20:32:59 +00:00
Boris Zbarsky 7472066554 Bug 1613571. Align service worker invalid-script-url and invalid-scope-url checks better with the spec. r=dom-workers-and-storage-reviewers,perry
Behavior changes:

1) We now throw a TypeError, not a SecurityError, when the script URI scheme is
not 'http' or 'https', like the spec says to.

2) We now throw when the scope URI scheme is not 'http' or 'https', like the
spec says to.

3) We now throw a proper TypeError, not a DOMException, at the end of
CheckForSlashEscapedCharsInPath.

4) More informative error messages.

Differential Revision: https://phabricator.services.mozilla.com/D61782

--HG--
extra : moz-landing-system : lando
2020-02-06 19:56:31 +00:00
Kris Maglione 6dfb63c750 Bug 1582832: Part 3 - Correctly handle windowless BCs created for printing. r=nika
Differential Revision: https://phabricator.services.mozilla.com/D61006

--HG--
extra : moz-landing-system : lando
2020-02-06 19:08:06 +00:00
Kris Maglione 44fded86b2 Bug 1582832: Part 2 - Don't attach a BrowsingContext before a FrameLoader is initialized. r=nika
There are cases where the initial BrowsingContext that we create for a
FrameLoader will never have a DocShell created for it. In the particular case
when the frame it belongs to is part of an inactive document, trying to
eagerly attach the BrowsingContext ends up attaching it as an active child of
its parent BrowsingContext, when it should be either cached or detached. Which
causes no end of problems.

This patch delays attaching the BrowsingContext until the FrameLoader is
initialized, which solves most of these problems.

Differential Revision: https://phabricator.services.mozilla.com/D59009

--HG--
extra : moz-landing-system : lando
2020-02-06 19:08:04 +00:00
Kris Maglione 1722817403 Bug 1582832: Part 1 - Make FrameLoader owner rather than DocShell responsible for discarding a BC. r=nika
There are all sorts of lifecycle issues which arise from making DocShell
responsible for discarding BrowsingContexts. In this particular bug, we tend
to run into them in cases where we create a BrowsingContext for a FrameLoader,
and then never create a DocShell for it, leading to it never being destroyed.
But there are myriad other issues as well.

This patch moves the responsibility for BrowsingContext lifecycle management
to the FrameLoader/FrameLoaderOwner, rather than the DocShell, which makes
things more consistent, and more closely aligns with spec-defined behavior.

Differential Revision: https://phabricator.services.mozilla.com/D59008

--HG--
extra : moz-landing-system : lando
2020-02-06 19:07:56 +00:00
Boris Zbarsky eb44d8db75 Bug 1612529. document.open should clear form state from the SHEntry. r=smaug
Otherwise we're using state from the pre-open document for whatever content is
being written, which is not likely to be right.

Differential Revision: https://phabricator.services.mozilla.com/D61865

--HG--
extra : moz-landing-system : lando
2020-02-06 17:49:44 +00:00