Commit Graph

8944 Commits

Author SHA1 Message Date
Brad Werth
94e5db7b03 Bug 1768495 Part 2: Pause or resume compositor when CanonicalBrowsingContext recomputes its visibility. r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D169345
2023-02-28 23:16:56 +00:00
Andreas Farre
3575a37276 Bug 1775927 - Make sure progress listener isn't gc'd. r=peterv
nsIWebProgressListener is stored as a weak reference in
nsIWebProgress. To not have it garbage collected we need to keep a
reference to it.

Differential Revision: https://phabricator.services.mozilla.com/D171228
2023-02-28 15:57:19 +00:00
Makoto Kato
aa3ccd258b Bug 1618885 - Remove unused is_fennec. r=jmaher,geckoview-reviewers,extension-reviewers,credential-management-reviewers,sgalich,robwu,calu
is_fennec is unused now, let's remove it.

Differential Revision: https://phabricator.services.mozilla.com/D170849
2023-02-27 01:44:18 +00:00
Peter Van der Beken
ff0a13060a Bug 1818124 - Perma [tier 2] /builds/worker/checkouts/gecko/docshell/test/navigation/test_blockBFCache.html:101:5 | Unknown property access Services.appinfo.fission. r=farre
Differential Revision: https://phabricator.services.mozilla.com/D170679
2023-02-25 17:26:41 +00:00
Julian Descottes
b52f247f59 Bug 1816898 - Fix docshell/test/unit/test_allowJavascript.js for thunderbird r=nika
The browsing context might be replaced after the navigation

Differential Revision: https://phabricator.services.mozilla.com/D170596
2023-02-23 21:35:20 +00:00
Peter Van der Beken
f1d59a32c8 Bug 1804803 - Hit MOZ_CRASH(DocumentLoadListener::Open for invalid history entry due to mismatch of 'Invalid LoadId'). r=smaug
When we start the load for a reload, check that the entry we're trying to
reload is still connected to session history.

Differential Revision: https://phabricator.services.mozilla.com/D165049
2023-02-21 15:09:09 +00:00
Peter Van der Beken
bffd25e220 Bug 1816697 - Fix chrome tests that fail if session-history-in-parent is enabled without Fission. r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D169825
2023-02-21 14:58:35 +00:00
Peter Van der Beken
d6fe05cdfd Bug 1816697 - Change test annotations for tests that fail/only succeed with session-history-in-parent. r=smaug
Some of the tests that fail (or only succeed) with SHIP are currently marked for
Fission. This makes them fail once we turn on SHIP without Fission.

Differential Revision: https://phabricator.services.mozilla.com/D169824
2023-02-21 14:58:35 +00:00
Emilio Cobos Álvarez
e22c322da5 Bug 1812868 - Tweak RDM and theme setup. r=mstange
This is in order to make nsPresContext::UseOverlayScrollbars() thread-safe for
stylo usage.

Document::GetBrowsingContext() does ref-counting of main-thread-only
objects, and we don't want that.

Similarly nsPresContext::Theme() mutates the pres context which is not
something we can do from multiple threads.

Reviewed in: https://phabricator.services.mozilla.com/D168148
2023-02-20 00:01:11 +01:00
Sandor Molnar
2bc700c04b Backed out 2 changesets (bug 1812868) for causing bug 1817539. CLOSED TREE
Backed out changeset 07c689de250c (bug 1812868)
Backed out changeset e7d370501c50 (bug 1812868)
2023-02-18 09:34:04 +02:00
Emilio Cobos Álvarez
ad4bd6a3ba Bug 1812868 - Expose scrollbar-inline-size as a CSS variable to chrome code. r=mstange
For that we need to:

 * Make GetDPIRatioForScrollbarPart thread-safe: This was using the
   widget for bug 1727289, but just looking at the print preview scale
   is enough to fix that.

 * Make nsPresContext::UseOverlayScrollbars() thread-safe: We store the
   RDM pane stuff in the pres context.

The rest is pretty straight-forward.

Differential Revision: https://phabricator.services.mozilla.com/D168148
2023-02-17 21:15:06 +00:00
Emilio Cobos Álvarez
be40d4df76 Bug 1814668 - Fix viewport size invalidation on MVM changes. r=hiro
The MVM doesn't change the document viewer bounds nor the view manager
bounds (maybe it used to?). Right now when exiting RDM, depending on the
order of operations (if MVM reset is the last thing to happen) we end up
with a wrong viewport size, because nsDocShell::SetSize is
short-circuited here[1].

Instead, force a resize reflow with the current dimensions which is what
the dynamic toolbar code also does, for example.

[1]: https://searchfox.org/mozilla-central/rev/5ccb73c0217d1710b10d6e6e297cf3396d10ec23/view/nsViewManager.cpp#172

Differential Revision: https://phabricator.services.mozilla.com/D169806
2023-02-15 13:58:40 +00:00
Emilio Cobos Álvarez
5e8315e1d3 Bug 1814668 - Invalidate media queries when BrowsingContext::TouchEventsOverride changes. r=hiro
Refactor the code a little bit to share more code.

Differential Revision: https://phabricator.services.mozilla.com/D169805
2023-02-15 13:57:59 +00:00
Daisuke Akatsuka
3093cbbf0a Bug 1733045: Remove nsINavBookmarkObserver. r=mak
Depends on D169583

Differential Revision: https://phabricator.services.mozilla.com/D131754
2023-02-15 00:29:13 +00:00
Joel Maher
a62ef05cdb Bug 1816191 - Skip tests in order to keep win7 running @ azure. r=gbrown,necko-reviewers,settings-reviewers,application-update-reviewers,media-playback-reviewers,credential-management-reviewers,nalexander,sgalich,alwu
Differential Revision: https://phabricator.services.mozilla.com/D169523
2023-02-14 23:44:12 +00:00
Peter Van der Beken
de3979ca1f Bug 1816234 - Fix meta refresh with SHIP. r=smaug
BrowsingContext::ShouldAddEntryForRefresh expects to be passed the current URI,
to determine if it's the same as the URI for the new load (we shouldn't add a
new entry if they are the same). Before this patch, in the child process we call
BrowsingContext::ShouldAddEntryForRefresh from nsDocShell::MoveLoadingToActiveEntry
(nsDocShell::CreateContentViewer -> Embed -> MoveLoadingToActiveEntry), passing
nsDocShell's mCurrentURI. However, by that point nsDocShell::CreateContentViewer
has already set the mCurrentURI to the newly loading URI (through
nsDocShell::OnNewURI). In the parent process we do pass the correct URI to
BrowsingContext::ShouldAddEntryForRefresh, so the session history ends up being
correct, but depending on timing of the IPC messages there's a brief moment where
index and length are incorrect in the child process (child process and parent
process get a different answer from BrowsingContext::ShouldAddEntryForRefresh).
This causes intermittent failures in the test at
docshell/test/mochitest/test_bug1742865.html.

Differential Revision: https://phabricator.services.mozilla.com/D169544
2023-02-14 10:19:54 +00:00
Gijs Kruitbosch
387cf24ca0 Bug 1810141 - fix tests to deal with changes to loadURI, r=mossop,perftest-reviewers,geckoview-reviewers,extension-reviewers,sparky,owlish
Depends on D168396

Differential Revision: https://phabricator.services.mozilla.com/D168397
2023-02-13 23:50:41 +00:00
Gijs Kruitbosch
9340b9bc7e Bug 1810141 - make docshell/nsIWebNavigation's loadURI actually take a URI object rather than a string, r=nika
Depends on D168390

Differential Revision: https://phabricator.services.mozilla.com/D168391
2023-02-13 23:50:39 +00:00
Gijs Kruitbosch
9d7452a247 Bug 1810141 - update consumers of CanonicalBrowsingContext.loadURI to use fixup or pass a URI object if they have it, r=mak,webdriver-reviewers,whimboo
Depends on D168389

Differential Revision: https://phabricator.services.mozilla.com/D168390
2023-02-13 23:50:38 +00:00
Gijs Kruitbosch
57b6bd03cd Bug 1810141 - make browsingcontext's loadURI actually take a URI rather than a string, r=nika
Differential Revision: https://phabricator.services.mozilla.com/D168389
2023-02-13 23:50:38 +00:00
Julian Descottes
66eca9e88c Bug 1757457 - [devtools] Recompute mCanExecuteScripts after navigation r=smaug
I can see that after navigation, allowJavascript is correctly set for the browsing context, but it seems we need to call
RecomputeCanExecuteScripts() to force it to be applied to the new page. Not sure if doing this here makes sense or if it should be done earlier.

Also there are still other issues with this feature:
- closing the toolbox does not reload the page: meaning JavaScript remains disabled on the page
- similarly all pages which have been put in bfcache will retain the javascript disabled/enabled setting

For the first issue, I wonder if we should force a reload when closing the toolbox (iff javascript disabled was toggled).
And for the second issue, could we invalidate contexts put in bfcache for a given browsing context when we toggle allowJavaScript?

Olli: Does this change make sense at least to fix the basic issue?

Differential Revision: https://phabricator.services.mozilla.com/D169182
2023-02-13 17:52:51 +00:00
Cristina Horotan
5f4356e527 Backed out 9 changesets (bug 1810141) for several test failures on a CLOSED TREE
Backed out changeset 8781a0d1254d (bug 1810141)
Backed out changeset 131037295784 (bug 1810141)
Backed out changeset 3852fbe290f4 (bug 1810141)
Backed out changeset 118f131a524a (bug 1810141)
Backed out changeset ab5d76846e10 (bug 1810141)
Backed out changeset dce3aa683445 (bug 1810141)
Backed out changeset 4dc41d90dbb3 (bug 1810141)
Backed out changeset 50b57ba1a061 (bug 1810141)
Backed out changeset 569de94781e4 (bug 1810141)
2023-02-13 16:05:30 +02:00
Gijs Kruitbosch
ff1cc20bd7 Bug 1810141 - fix tests to deal with changes to loadURI, r=mossop,perftest-reviewers,geckoview-reviewers,extension-reviewers,sparky,owlish
Depends on D168396

Differential Revision: https://phabricator.services.mozilla.com/D168397
2023-02-13 12:55:26 +00:00
Gijs Kruitbosch
60d67bb0ad Bug 1810141 - make docshell/nsIWebNavigation's loadURI actually take a URI object rather than a string, r=nika
Depends on D168390

Differential Revision: https://phabricator.services.mozilla.com/D168391
2023-02-13 12:55:23 +00:00
Gijs Kruitbosch
e460aa10f3 Bug 1810141 - update consumers of CanonicalBrowsingContext.loadURI to use fixup or pass a URI object if they have it, r=mak,webdriver-reviewers,whimboo
Depends on D168389

Differential Revision: https://phabricator.services.mozilla.com/D168390
2023-02-13 12:55:22 +00:00
Gijs Kruitbosch
4cd5a989e5 Bug 1810141 - make browsingcontext's loadURI actually take a URI rather than a string, r=nika
Differential Revision: https://phabricator.services.mozilla.com/D168389
2023-02-13 12:55:22 +00:00
Cristian Tuns
b25ff1fab8 Backed out 3 changesets (bug 1768495) for causing reftest failures in 1478035.html CLOSED TREE
Backed out changeset 6a48a9418fb3 (bug 1768495)
Backed out changeset ac0c0d68e31d (bug 1768495)
Backed out changeset 74c1903a5df6 (bug 1768495)
2023-02-09 21:31:43 -05:00
Brad Werth
421dfdd517 Bug 1768495 Part 2: Pause or resume compositor when CanonicalBrowsingContext recomputes its visibility. r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D169345
2023-02-09 23:44:19 +00:00
Emilio Cobos Álvarez
d28f1e4d47 Bug 1815255 - Fix tests to deal with flexbox emulation. r=Jamie,Gijs
Mostly changing XUL attributes to CSS properties, though there are a few
tricky ones:

 * test_offsets.xhtml expects the scroller to be full-width, while
   modern flexbox would honor width: 200px (so just remove it).

 * window_intrinsic_size.xhtml was relying on the div imposing a XUL
   min-size (the test is for SetSizeConstraints, bug 1447056). Use
   min-height instead as that's what modern flexbox reads. Confirmed
   that bug doesn't regress in any case.

 * object-fit-contain-png-001.xhtml has a float: left which had no
   effect on -moz-box, but which assert with modern layout[1]. In the
   future I think we could remove that assert but anyways, for now just
   keeping behavior.

 * image-size.xhtml has a couple uninvestigated sizing differences. They
   didn't seem problematic.

 * 579323-1-ref.html changes because the other file has a canvas with
   width=100 height=100 which imposes an aspect ratio (which XUL never
   honored).

 * window_largemenu.xhtml shows a regression, but this never worked on
   some platforms (at least Linux+Wayland) and nobody has noticed it in
   the browser area, so I suspect we're fine.

[1]: https://searchfox.org/mozilla-central/rev/08362489086b10de96e7a199b267ea5504c01583/layout/generic/ReflowInput.cpp#2137

Differential Revision: https://phabricator.services.mozilla.com/D169084
2023-02-09 12:24:53 +00:00
Nazım Can Altınova
3c14a0bff0 Bug 1812368 - Truncate the URLs we are passing into profiler markers r=julienw
Differential Revision: https://phabricator.services.mozilla.com/D169053
2023-02-09 10:16:51 +00:00
Marian-Vasile Laza
7675a138b5 Backed out 2 changesets (bug 1815255) for causing reftest failures. CLOSED TREE
Backed out changeset b1173e8c7497 (bug 1815255)
Backed out changeset bd09cf2a4abb (bug 1815255)
2023-02-09 04:26:01 +02:00
Emilio Cobos Álvarez
656f11b2a0 Bug 1815255 - Fix tests to deal with flexbox emulation. r=Jamie,Gijs
Mostly changing XUL attributes to CSS properties, though there are a few
tricky ones:

 * test_offsets.xhtml expects the scroller to be full-width, while
   modern flexbox would honor width: 200px (so just remove it).

 * window_intrinsic_size.xhtml was relying on the div imposing a XUL
   min-size (the test is for SetSizeConstraints, bug 1447056). Use
   min-height instead as that's what modern flexbox reads. Confirmed
   that bug doesn't regress in any case.

 * object-fit-contain-png-001.xhtml has a float: left which had no
   effect on -moz-box, but which assert with modern layout[1]. In the
   future I think we could remove that assert but anyways, for now just
   keeping behavior.

 * image-size.xhtml has a couple uninvestigated sizing differences. They
   didn't seem problematic.

 * 579323-1-ref.html changes because the other file has a canvas with
   width=100 height=100 which imposes an aspect ratio (which XUL never
   honored).

 * window_largemenu.xhtml shows a regression, but this never worked on
   some platforms (at least Linux+Wayland) and nobody has noticed it in
   the browser area, so I suspect we're fine.

[1]: https://searchfox.org/mozilla-central/rev/08362489086b10de96e7a199b267ea5504c01583/layout/generic/ReflowInput.cpp#2137

Differential Revision: https://phabricator.services.mozilla.com/D169084
2023-02-09 00:55:13 +00:00
Cristina Horotan
fbcc0f66b4 Backed out 2 changesets (bug 1815255) for causing chrome failures at test_focus.xhtml on a CLOSED TREE
Backed out changeset 983fe4e70647 (bug 1815255)
Backed out changeset f8c6426c60f9 (bug 1815255)
2023-02-08 19:50:19 +02:00
Emilio Cobos Álvarez
5db814c383 Bug 1815255 - Fix tests to deal with flexbox emulation. r=Jamie,Gijs
Mostly changing XUL attributes to CSS properties, though there are a few
tricky ones:

 * test_offsets.xhtml expects the scroller to be full-width, while
   modern flexbox would honor width: 200px (so just remove it).

 * window_intrinsic_size.xhtml was relying on the div imposing a XUL
   min-size (the test is for SetSizeConstraints, bug 1447056). Use
   min-height instead as that's what modern flexbox reads. Confirmed
   that bug doesn't regress in any case.

 * object-fit-contain-png-001.xhtml has a float: left which had no
   effect on -moz-box, but which assert with modern layout[1]. In the
   future I think we could remove that assert but anyways, for now just
   keeping behavior.

 * image-size.xhtml has a couple uninvestigated sizing differences. They
   didn't seem problematic.

 * 579323-1-ref.html changes because the other file has a canvas with
   width=100 height=100 which imposes an aspect ratio (which XUL never
   honored).

 * window_largemenu.xhtml shows a regression, but this never worked on
   some platforms (at least Linux+Wayland) and nobody has noticed it in
   the browser area, so I suspect we're fine.

[1]: https://searchfox.org/mozilla-central/rev/08362489086b10de96e7a199b267ea5504c01583/layout/generic/ReflowInput.cpp#2137

Differential Revision: https://phabricator.services.mozilla.com/D169084
2023-02-08 16:52:18 +00:00
Jens Stutte
a5cf43833e Bug 1814603 - Change more ContentParent::IsDead checks to ContentParent::IsShuttingDown. r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D168995
2023-02-07 18:07:19 +00:00
Greg Tatum
a254222081 Bug 1805476 - Stub out an about:translations page with no real functionality; r=nordzilla
This page is hidden behind a pref, but not behind an ifdef. I chose to
do this in order to simplify the potential release of this feature. I
don't foresee issues with bloating the binary during the development,
so this doesn't feel like a risk to me.

Differential Revision: https://phabricator.services.mozilla.com/D164613
2023-02-06 21:56:37 +00:00
Jens Stutte
75a94959cb Bug 1813391 - Have ContentParent::IsShuttingDown and check it instead of IsAlive where appropriate. r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D168225
2023-02-01 15:50:49 +00:00
Olli Pettay
2cc9c7eaf8 Bug 1810903, return early from LoadErrorPage if the docshell is going away, r=peterv
We'd return early anyhow later in nsDocShell::InternalLoad.
The patch is based on code inspection. If one is closing the window while printing, we could get to this state, among other cases.

Differential Revision: https://phabricator.services.mozilla.com/D168368
2023-01-31 13:47:50 +00:00
Gijs Kruitbosch
c906d6f529 Bug 1795255 - manual fixes for tests that break after applying this lint rule, r=Standard8,necko-reviewers,extension-reviewers,credential-management-reviewers,sgalich,willdurand
Differential Revision: https://phabricator.services.mozilla.com/D167802
2023-01-31 11:48:41 +00:00
Stanca Serban
373a25b201 Merge mozilla-central to autoland. CLOSED TREE 2023-01-25 11:48:07 +02:00
Stanca Serban
e1b4aec181 Backed out changeset efdaaeb6ecf2 (bug 1804803) for causing Bug 1812257. a=backout 2023-01-25 11:41:08 +02:00
Gijs Kruitbosch
129735a58b Bug 1811854 - switch remaining tests to BrowserTestUtils.loadURIString from BrowserTestUtils.loadURI, r=Standard8
Differential Revision: https://phabricator.services.mozilla.com/D167558
2023-01-24 13:19:11 +00:00
Peter Van der Beken
12f9eda269 Bug 1804803 - Hit MOZ_CRASH(DocumentLoadListener::Open for invalid history entry due to mismatch of 'Invalid LoadId'). r=smaug
When we start the load for a reload, check that the entry we're trying to
reload is still connected to session history.

Differential Revision: https://phabricator.services.mozilla.com/D165049
2023-01-24 11:11:26 +00:00
Emilio Cobos Álvarez
9e530f224a Bug 1811834 - Clean up nsWidgetInitData. r=cmartin,geckoview-reviewers,calu
Move it to the mozilla::widget namespace.

Use enum classes for transparency, popup type, popup level, etc.

Mostly automated with sed, but there were a few manual changes required
as well in windows code because they relied on Atomic<TransparencyMode>
working (which now doesn't because TransparencyMode is 1 byte instead of
4 bytes).

Differential Revision: https://phabricator.services.mozilla.com/D167537
2023-01-23 23:58:41 +00:00
Olli Pettay
ee07926a1f Bug 1803628, initiate frameloader destroy asynchronously, r=mccr8
Differential Revision: https://phabricator.services.mozilla.com/D166830
2023-01-20 16:39:39 +00:00
Gijs Kruitbosch
cb015ad1d8 Bug 1810995 - update BrowserTestUtils.loadURI consumers to use loadURIString (automated) - dom and docshell - r=Standard8
Differential Revision: https://phabricator.services.mozilla.com/D167152
2023-01-19 20:16:41 +00:00
Cosmin Sabou
0869b4045d Backed out changeset 7e708c1c9d9d (bug 1805182) for causing SessionHistory related failures. 2023-01-19 19:37:59 +02:00
Sean Feng
930130580b Bug 1805182 - Fix the bug where postData is lost when the LoadingSessionHistoryEntry is replaced for redirect r=peterv
The postData should be carried over when we replace the
LoadingSessionHistoryEntry for the redirect.

Differential Revision: https://phabricator.services.mozilla.com/D166176
2023-01-19 15:34:47 +00:00
Emilio Cobos Álvarez
2a47aa3103 Bug 1569439 - Cleanup tooltip pref handling. r=stransky
Differential Revision: https://phabricator.services.mozilla.com/D166943
2023-01-19 10:28:28 +00:00
Adam Vandolder
1267f7d14f Bug 1509346 - Add support for <form rel>. r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D166489
2023-01-18 16:41:04 +00:00