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

25359 Коммитов

Автор SHA1 Сообщение Дата
Emilio Cobos Álvarez 6af42b7029 Bug 1771791 - Use regular ComputeIndexOf in ComputeFlatTreeIndexOf if there's no Shadow DOM involved. r=mrobinson
Untested, but seems like it should address the regression.

Differential Revision: https://phabricator.services.mozilla.com/D147865
2022-06-02 09:24:16 +00:00
Bogdan Szekely 52d27bde15 Backed out 2 changesets (bug 1352532) for causing some regressions. CLOSED TREE
Backed out changeset e2dd95957747 (bug 1352532)
Backed out changeset 1a3be3ef674c (bug 1352532)
2022-06-02 12:02:02 +03:00
ahochheiden 964834abba Bug 1769631 - Remove 'U' from 'mode' parameters for various 'open' calls to ensure Python3.11 compatibility r=firefox-build-system-reviewers,glandium
The 'U' flag represents "universal newline". It has been deprecated
since Python3.3. Since then "universal newline" is the default when a
file is opened in text mode (not bytes). In Python3.11 using the 'U'
flag throws errors. There should be no harm in removing 'U' from 'open'
everywhere it is used, and doing allows the use of Python3.11.

For more reading see: https://docs.python.org/3.11/whatsnew/3.11.html#changes-in-the-python-api

Differential Revision: https://phabricator.services.mozilla.com/D147721
2022-06-02 06:27:44 +00:00
Emilio Cobos Álvarez 7cf84b6b76 Bug 1771938 - Add a cache for nsContentList::NamedItem. r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D147789
2022-06-01 22:01:29 +00:00
Butkovits Atila b549b7d40c Backed out changeset a12003bc125a (bug 1771938) for failures complaining about HTMLTableCellElement. CLOSED TREE 2022-06-01 20:53:09 +03:00
Emilio Cobos Álvarez 8a7e3ba9f5 Bug 1771938 - Add a very simple cache for nsContentList::NamedItem. r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D147789
2022-06-01 16:05:53 +00:00
Benjamin VanderSloot 57e04b3f43 Bug 1765307, part 6 - Add inline comments to explain changes from this set, r=anti-tracking-reviewers,timhuang
Differential Revision: https://phabricator.services.mozilla.com/D147333
2022-06-01 14:37:07 +00:00
Benjamin VanderSloot 93b5f8f8aa Bug 1765307, part 5 - Make requestStorageAccessForOrigin check cookie permissions in the parent process, r=anti-tracking-reviewers,timhuang
Also remove the old IPC that did this.

Differential Revision: https://phabricator.services.mozilla.com/D146946
2022-06-01 14:37:07 +00:00
Benjamin VanderSloot 03eca51897 Bug 1765307, part 4 - Update requestStorageAccess[ForOrigin] functions to use helper functino for the asynchronous portion, r=anti-tracking-reviewers,timhuang
Differential Revision: https://phabricator.services.mozilla.com/D146618
2022-06-01 14:37:06 +00:00
Benjamin VanderSloot 8dcc2921dd Bug 1765307, part 3 - Create helper for the async portion of the requestStorageAccess[ForOrigin] functions, r=anti-tracking-reviewers,timhuang
Differential Revision: https://phabricator.services.mozilla.com/D146617
2022-06-01 14:37:06 +00:00
Benjamin VanderSloot d3c2248593 Bug 1765307, part 2 - Convert privileged API to use helpers for the synchronous portion, r=anti-tracking-reviewers,timhuang
Differential Revision: https://phabricator.services.mozilla.com/D146616
2022-06-01 14:37:06 +00:00
Emilio Cobos Álvarez a6ed65f83e Bug 1772083 - Downgrade an assertion for now while we try to find STR. r=smaug
The only URLs in the crash reports are internal networks, so it's not
clear to me how it can happen. But given it can, handle it gracefully.

Differential Revision: https://phabricator.services.mozilla.com/D147856
2022-06-01 14:03:04 +00:00
Emilio Cobos Álvarez aee6bfe7dc Bug 1771959 - Use inline initializers and an Element typedef in nsContentList. r=smaug
Depends on D147787

Differential Revision: https://phabricator.services.mozilla.com/D147788
2022-06-01 09:21:15 +00:00
Emilio Cobos Álvarez 25103377c3 Bug 1771959 - Check mFushesNeeded first, since it's usually false for html. r=smaug
Depends on D147786

Differential Revision: https://phabricator.services.mozilla.com/D147787
2022-06-01 09:21:15 +00:00
Emilio Cobos Álvarez 3cec69329b Bug 1771959 - Remove unneeded virtual in nsContentList.h. r=smaug
Depends on D147785

Differential Revision: https://phabricator.services.mozilla.com/D147786
2022-06-01 09:21:14 +00:00
Emilio Cobos Álvarez 62f7dd3e76 Bug 1771959 - Make nsContentList state an enum class. r=smaug
And cleanup bitfields, we don't care about msvc anymore.

Differential Revision: https://phabricator.services.mozilla.com/D147785
2022-06-01 09:21:14 +00:00
Emilio Cobos Álvarez 27e31ed3bf Bug 1771571 - Fix include header mess between frame constructor / restyle manager. r=layout-reviewers,AlaskanEmily
RestyleManager includes nsPresContextInlines which includes
nsCSSFrameConstructor which includes RestyleManager.

Break the cycle, since turns out the later include is not needed.

Differential Revision: https://phabricator.services.mozilla.com/D147560
2022-05-31 20:07:38 +00:00
Edgar Chen ff60ecba27 Bug 1757531 - Do not forward focus to child frame when calling window.focus() on parent frame; r=hsivonen
Differential Revision: https://phabricator.services.mozilla.com/D146446
2022-05-31 19:59:39 +00:00
Emilio Cobos Álvarez b5c972f5f5 Bug 1771742 - Fix behavior change caught by WPT.
MANUAL PUSH: Trivial orange fix CLOSED TREE
2022-05-30 18:18:56 +02:00
Butkovits Atila 1f108c2a9a Backed out changeset 630c31f32767 (bug 1757531) for causing wpt failures at activeelement-after-calling-window-focus.sub.html. CLOSED TREE 2022-05-30 18:03:23 +03:00
Emilio Cobos Álvarez 296854a5fa Bug 1771742 - Speed up nsContentList::NamedItem. r=smaug
Check the "has id / name" flags before checking the attributes, and do
only one walk over the attributes rather than two.

Differential Revision: https://phabricator.services.mozilla.com/D147663
2022-05-30 14:38:44 +00:00
Jon Coppeard dbe179c474 Bug 1352532 - Part 1: Allow wrapper cache to handle changing a nursery wrapper to another nursery wrapper r=smaug
Previously this situation didn't arise and the existing code calls
NurseryWrapperAdded multiple times with the same wrapper in this case. This
causes assertion failures when the nursery wrapper list is processed later on.

Differential Revision: https://phabricator.services.mozilla.com/D146804
2022-05-30 14:24:51 +00:00
Andrew McCreight 8bcddc94c2 Bug 1771565, part 2 - Remove XUL stuff from test_bug564863.xhtml. r=smaug
This removes XUL stuff from the Mochitest plain, so we don't need
to rely on allowXULXBL.

It also fixes up test_bug564863-2.xhtml to run as a mochitest-chrome.
It removes all of the non-XUL stuff, as that's being tested in the existing
test. I also commented out the is(xul_cs.color, "rgb(0, 0, 0)") check
as that seems to fail when this test is run as a Mochitest chrome
(for everything, not just XUL) and I didn't want to investigate
why.

Differential Revision: https://phabricator.services.mozilla.com/D147558
2022-05-30 13:34:51 +00:00
Andrew McCreight 7c821f83c8 Bug 1771565 - Copy test_bug564863.xhtml to a new test. r=smaug
The hope is to help preserve blame this way.

Differential Revision: https://phabricator.services.mozilla.com/D147557
2022-05-30 13:34:50 +00:00
Edgar Chen 6a85d3f818 Bug 1757531 - Do not forward focus to child frame when calling window.focus() on parent frame; r=hsivonen
Differential Revision: https://phabricator.services.mozilla.com/D146446
2022-05-30 12:59:48 +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
Emilio Cobos Álvarez 9c190fff4b Bug 1771564 - Constify ComputedStyle usage in nsComputedDOMStyle. r=dholbert
None of the consumer need to mutate styles, and this saves some ugly
const_casting on the next patch.

Doesn't change behavior.

Differential Revision: https://phabricator.services.mozilla.com/D147555
2022-05-28 01:04:24 +00:00
Steve Fink 819ec57dae Bug 1735434 - Gather additional information for cycle collection profiler markers r=mccr8
Differential Revision: https://phabricator.services.mozilla.com/D128316
2022-05-27 23:42:54 +00:00
Narcis Beleuzu e3d25251cc Backed out changeset 7f67e3634e8f (bug 1735434) for multiple failures/crashes on nsJSEnvironment.cpp . CLOSED TREE 2022-05-27 19:39:37 +03:00
Steve Fink ab9c7c302b Bug 1735434 - Gather additional information for cycle collection profiler markers r=mccr8
Differential Revision: https://phabricator.services.mozilla.com/D128316
2022-05-27 15:44:22 +00:00
criss 60af38395c Backed out 6 changesets (bug 1765307) as per dev's request. CLOSED TREE
Backed out changeset 56feedc5c0a3 (bug 1765307)
Backed out changeset 44991705d133 (bug 1765307)
Backed out changeset 417de8ef5343 (bug 1765307)
Backed out changeset 351f1d3fd689 (bug 1765307)
Backed out changeset babee487e11f (bug 1765307)
Backed out changeset 0c341bc2a708 (bug 1765307)
2022-05-27 17:30:03 +03:00
Kagami Sascha Rosylight 490bd934d0 Bug 1771009 - Make TimeoutManager::SetTimeout no-op if window is dying r=smaug
setTimeout is not affected since nsGlobalWindowInner::SetTimeout is not called at all when it's dying, but that's not the case with AbortSignal.timout, so we have to explicitly deal with such situation.

Differential Revision: https://phabricator.services.mozilla.com/D147368
2022-05-27 14:02:53 +00:00
Iulian Moraru 74097ce09d Backed out changeset f29c1f743f52 (bug 1771009) for causing failures on timeout-close.html. CLOSED TREE 2022-05-27 02:02:16 +03:00
Kagami Sascha Rosylight 090cf33807 Bug 1771009 - Make TimeoutManager::SetTimeout no-op if window is dying r=smaug
setTimeout is not affected since nsGlobalWindowInner::SetTimeout is not called at all when it's dying, but that's not the case with AbortSignal.timout, so we have to explicitly deal with such situation.

Differential Revision: https://phabricator.services.mozilla.com/D147368
2022-05-26 22:12:48 +00:00
Emilio Cobos Álvarez 812e9972e6 Bug 1730284 - Minor fix so this works for in-process frames in DevTools properly.
Otherwise if *this is the top-level document IntersectionObserver won't
quite do the right thing.

MANUAL PUSH: Fix orange timeout CLOSED TREE
2022-05-26 19:58:56 +02:00
Emilio Cobos Álvarez 25f894d32e Bug 1730284 - Fix new test in XOrigin mode.
MANUAL PUSH: Trivial fix for new test CLOSED TREE.
2022-05-26 19:21:12 +02:00
Martin Robinson cac491e1fd Bug 1477524 - Update quotes and counters to work trough the flattened tree r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D146693
2022-05-26 16:12:46 +00:00
Emilio Cobos Álvarez 614a085bf3 Bug 1730284 - Use whether the embedder element intersects the viewport to decide whether to throttle in-process iframes. r=smaug
This is more likely to be understandable by developers, matches other
browsers more closely (see bug comments), and seems more in-line with
what we do for OOP iframes.

Add a pref to not do this throttling at all (which would match Chrome),
though this is probably good enough for now.

Differential Revision: https://phabricator.services.mozilla.com/D146574
2022-05-26 15:45:01 +00:00
Norisz Fay 28db98ade1 Backed out changeset ce66cc2cbb95 (bug 1477524) for causing build bustages on nsCounterManager.cpp CLOSED TREE 2022-05-26 15:24:40 +03:00
Benjamin VanderSloot 00a98e3ed5 Bug 1765307, part 6 - Add inline comments to explain changes from this set, r=anti-tracking-reviewers,timhuang
Differential Revision: https://phabricator.services.mozilla.com/D147333
2022-05-26 11:18:58 +00:00
Benjamin VanderSloot c81e491ae4 Bug 1765307, part 5 - Make requestStorageAccessForOrigin check cookie permissions in the parent process, r=anti-tracking-reviewers,timhuang
Also remove the old IPC that did this.

Differential Revision: https://phabricator.services.mozilla.com/D146946
2022-05-26 11:18:57 +00:00
Benjamin VanderSloot 0e7849fdab Bug 1765307, part 4 - Update requestStorageAccess[ForOrigin] functions to use helper functino for the asynchronous portion, r=anti-tracking-reviewers,timhuang
Differential Revision: https://phabricator.services.mozilla.com/D146618
2022-05-26 11:18:57 +00:00
Benjamin VanderSloot b453919747 Bug 1765307, part 3 - Create helper for the async portion of the requestStorageAccess[ForOrigin] functions, r=anti-tracking-reviewers,timhuang
Differential Revision: https://phabricator.services.mozilla.com/D146617
2022-05-26 11:18:57 +00:00
Benjamin VanderSloot b6c392d6da Bug 1765307, part 2 - Convert privileged API to use helpers for the synchronous portion, r=anti-tracking-reviewers,timhuang
Differential Revision: https://phabricator.services.mozilla.com/D146616
2022-05-26 11:18:56 +00:00
Martin Robinson 786890b5c4 Bug 1477524 - Update quotes and counters to work trough the flattened tree r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D146693
2022-05-26 11:15:16 +00:00
Masayuki Nakano 6440fbddc3 Bug 1770133 - part 4: Make `IMEContentObserver` use `dom::Element` instead of `nsIContent` for root r=m_kato
The root is always an element node.  So, it should take and store the root node
as `dom::Element` rather than `nsIContent`.

Differential Revision: https://phabricator.services.mozilla.com/D147135
2022-05-26 07:03:20 +00:00
Masayuki Nakano 6817b54c9d Bug 1770133 - part 2: Make `IMEStateManager::sFocusedContent` store it as `Element` r=m_kato
`nsFocusManager` defines that focused content is at least `dom::Element`.
So `IMEStateManager` can handle focused content with `dom::Element` too.

Additionally, this patch makes `IMEStateManager` methods take references instead
of pointers as far as possible if they just return error for `nullptr`.

Differential Revision: https://phabricator.services.mozilla.com/D147133
2022-05-26 07:03:19 +00:00
Masayuki Nakano 5a48a0f346 Bug 1680611 - part 11: Mark `nsFocusManager::NotifyOfReFocus()` as `MOZ_CAN_RUN_SCRIPT` r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D147072
2022-05-26 04:37:22 +00:00
Masayuki Nakano 971efcf6d8 Bug 1770684 - Mark `IMEStateManager::SetIMEState` and its callers in `IMEStateManager` as `MOZ_CAN_RUN_SCRIPT` r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D147071
2022-05-26 04:37:21 +00:00
Masayuki Nakano 77df1d2c4c Bug 1680611 - part 10: Mark `nsFocusManager::Flush*()` and their callers in `nsFocusManager` r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D147069
2022-05-26 04:37:21 +00:00