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

2667 Коммитов

Автор SHA1 Сообщение Дата
Csoregi Natalia f064bd5377 Backed out 4 changesets (bug 1751010) for win bustages on nsWindow.cpp. CLOSED TREE
Backed out changeset b68d86cc545d (bug 1751010)
Backed out changeset b51b389bd0fd (bug 1751010)
Backed out changeset f128c61e50eb (bug 1751010)
Backed out changeset 1cbe75d59770 (bug 1751010)
2022-02-22 21:17:27 +02:00
Ben Hearsum 40fe916224 Bug 1751010: Set AUMID correctly for private browsing windows r=mossop,mhowell
This is done differently depending on whether the Private Browsing window is the initial one, or if it's a new window from a running application. In the former case, we're still not setting it up early enough -- the window will initially show up in one icon, and then switch to the other one after we've adjusted the AUMID.

Regardless, the fact that we're doing it for every new window appears to mean that other places that require it (such as GeckoChildProcessHost.cpp) will Do The Right Thing (because they'll pull the cached version that `GetAppUserModelID` finds).

This behind a pref for now both because of the issue noted above, as well as the fact that we're waiting on finalized branding for this.

Differential Revision: https://phabricator.services.mozilla.com/D138194
2022-02-22 18:16:35 +00:00
Emilio Cobos Álvarez a8ddbfd586 Bug 1756323 - Fix tooltip coordinates in presence of full zoom. r=jfkthame
And cleanup similar code in nsXULTooltipListener. That code shouldn't
need to deal with zoom since the target and the tooltip are in the same
document.

Differential Revision: https://phabricator.services.mozilla.com/D139235
2022-02-21 17:30:08 +00:00
Matthew Gaudet bc10b96605 Bug 1748888 - Add ErrorResult parameter to PromiseNativeHandler callbacks r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D136423
2022-01-20 19:11:39 +00:00
Kagami Sascha Rosylight 496a0d78cc Bug 1539884 - Part 36: Mark AppWindow::ExecuteCloseHandler as CAN_RUN_SCRIPT r=masayuki
Differential Revision: https://phabricator.services.mozilla.com/D134474
2021-12-23 16:27:26 +00:00
Mark Smith ab672f30ec Bug 1586061: Prevent additional hidden windows from being created if one already exists on macOS. r=mstange
Differential Revision: https://phabricator.services.mozilla.com/D134055
2021-12-16 18:59:42 +00:00
Csoregi Natalia ee888bb9dd Backed out changeset 36f5dbe746ec (bug 1743486) for bustage on nsContentUtils.cpp. CLOSED TREE 2021-12-07 19:42:45 +02:00
codyd b6700e5c63 Bug 1743486: More Cut over for resistinfingerprinting API: UseStandinsForNativeColors and Appwindow r=tjr
Differential Revision: https://phabricator.services.mozilla.com/D132515
2021-12-07 16:32:05 +00:00
Tooru Fujisawa 4d7bcb01be Bug 1701001 - Part 2: Add "is popup" field to browsing context. r=smaug
Add BrowsingContext::FieldValues.mIsPopupRequested, and pass "is popup"
value calculated before opening window/tab to BrowsingContext::CreateDetached.

Other code path that is unrelated to content-priv window.open uses the
default value false.

Differential Revision: https://phabricator.services.mozilla.com/D129411
2021-11-06 01:19:14 +00:00
Tooru Fujisawa f11f62dcaf Bug 1701001 - Part 1: Standardize the condition for opening popup from window.open. r=smaug
Removed "width" feature from the popup condition, and removed related parameters
(aWidthSpecified, and aSizeSpec) from functions.

Also added "popup" feature that explicitly specify whether to request popup or
not.
This is only for content context, and it behaves differently than existing
"popup" feature for chrome context that makes the window no-style.

Differential Revision: https://phabricator.services.mozilla.com/D129410
2021-11-06 01:19:14 +00:00
Marian-Vasile Laza 4cbdb0eb2b Backed out 4 changesets (bug 1737832, bug 1701001) for causing geckoview failures on noopener-noreferrer-BarProp.window.html. CLOSED TREE
Backed out changeset ff439d9c0391 (bug 1701001)
Backed out changeset b0e47b1f4d39 (bug 1701001)
Backed out changeset 0e2ca3cc650e (bug 1701001)
Backed out changeset 712b897cbc76 (bug 1737832)
2021-11-06 02:44:46 +02:00
Tooru Fujisawa 0e16a22ff2 Bug 1701001 - Part 2: Add "is popup" field to browsing context. r=smaug
Add BrowsingContext::FieldValues.mIsPopupRequested, and pass "is popup"
value calculated before opening window/tab to BrowsingContext::CreateDetached.

Other code path that is unrelated to content-priv window.open uses the
default value false.

Differential Revision: https://phabricator.services.mozilla.com/D129411
2021-11-05 23:07:40 +00:00
Tooru Fujisawa 9f346830ab Bug 1701001 - Part 1: Standardize the condition for opening popup from window.open. r=smaug
Removed "width" feature from the popup condition, and removed related parameters
(aWidthSpecified, and aSizeSpec) from functions.

Also added "popup" feature that explicitly specify whether to request popup or
not.
This is only for content context, and it behaves differently than existing
"popup" feature for chrome context that makes the window no-style.

Differential Revision: https://phabricator.services.mozilla.com/D129410
2021-11-05 23:07:40 +00:00
Jens Stutte 0f4192786c Bug 1738185: Update the error handling in the mediator around mReady status. r=mccr8
mReady is false both before nsWindowMediator is initialized and after it observed xpcom-shutdown. In the latter case we can still receive Javascript calls as the service is not yet unregistered. We want to ensure that:

- we cannot register new windows anymore (this was already the case but we want to assert, too).
- we do not throw while asking for enumerators even late in shutdown, returning an empty enumerator.
- we assert on other late calls (but keep returning an error in non-debug).

Differential Revision: https://phabricator.services.mozilla.com/D129942
2021-11-03 15:25:10 +00:00
Michael Kohler c84c59e032 Bug 1672486 - Remove browser.toolbars.bookmarks.2h2020 pref from browser/customizableui/places r=mak
Differential Revision: https://phabricator.services.mozilla.com/D127588
2021-10-14 07:51:14 +00:00
criss 6c589aa7bd Backed out changeset da5a7c4478d9 (bug 1727815) for causing assertion failures on nsGlobalWindowOuter.cpp. CLOSED TREE 2021-10-12 12:45:26 +03:00
Alexander Taylor 38c27d5663 Bug 1727815 Toggle internal fullscreen even if window widget fullscreen not achieved r=stransky
Differential Revision: https://phabricator.services.mozilla.com/D123830
2021-10-12 07:57:48 +00:00
Jens Stutte ea47ed0285 Bug 1731564: Use motivated SpinEventLoopUntil inside xpfe/*. r=smaug
Depends on D127237

Differential Revision: https://phabricator.services.mozilla.com/D127238
2021-10-07 08:06:16 +00:00
Marian-Vasile Laza 18fb16c542 Backed out 18 changesets (bug 1731564) for causing build bustages on SpinEventLoopUntil. CLOSED TREE
Backed out changeset 0464dbdc8584 (bug 1731564)
Backed out changeset 0d996df13545 (bug 1731564)
Backed out changeset 5630a0e7a109 (bug 1731564)
Backed out changeset 37b41d187cdb (bug 1731564)
Backed out changeset d37700fa60b6 (bug 1731564)
Backed out changeset b0ce7db44b99 (bug 1731564)
Backed out changeset aa5ec3aa1535 (bug 1731564)
Backed out changeset 73b648f1fa70 (bug 1731564)
Backed out changeset bb8fb0f9833e (bug 1731564)
Backed out changeset 0d8905144f5d (bug 1731564)
Backed out changeset 2cfb094a1ec3 (bug 1731564)
Backed out changeset 78d3b0257a6a (bug 1731564)
Backed out changeset e9d32926e93c (bug 1731564)
Backed out changeset 874cab520ce5 (bug 1731564)
Backed out changeset d8071cc32bd9 (bug 1731564)
Backed out changeset 283c5393cbbc (bug 1731564)
Backed out changeset 317bc38e3de5 (bug 1731564)
Backed out changeset 53e3f4862439 (bug 1731564)
2021-10-07 00:09:19 +03:00
Jens Stutte 46c1a41f85 Bug 1731564: Use motivated SpinEventLoopUntil inside xpfe/*. r=smaug
Depends on D127237

Differential Revision: https://phabricator.services.mozilla.com/D127238
2021-10-06 19:45:18 +00:00
Botond Ballo 2ae2965a5a Bug 1695822 - Track mHasRemoteContent for windows created using nsAppShellService. r=hiro
Differential Revision: https://phabricator.services.mozilla.com/D125776
2021-09-17 21:42:15 +00:00
Andi-Bogdan Postelnicu 2fc4f70e9b Bug 1725145 - Preparation for the hybrid build env. r=necko-reviewers,firefox-build-system-reviewers,valentin,glandium
Automatically generated path that adds flag `REQUIRES_UNIFIED_BUILD = True` to `moz.build`
when the module governed by the build config file is not buildable outside on the unified environment.

This needs to be done in order to have a hybrid build system that adds the possibility of combing
unified build components with ones that are built outside of the unified eco system.

Differential Revision: https://phabricator.services.mozilla.com/D122345
2021-08-25 10:46:17 +00:00
Zibi Braniecki 92183f248d Bug 1613705 - [localization] part9: Update DOMLocalization to match Localization constructor. r=nika,emilio
Depends on D113691

Differential Revision: https://phabricator.services.mozilla.com/D113692
2021-08-03 16:25:13 +00:00
Butkovits Atila 949da905e7 Backed out 19 changesets (bug 1613705) for causing build bustages complaining about Document.cpp. CLOSED TREE
Backed out changeset 2ee1091dd20d (bug 1613705)
Backed out changeset d377afc0b09f (bug 1613705)
Backed out changeset de9d4378f0ac (bug 1613705)
Backed out changeset 9843372abb6e (bug 1613705)
Backed out changeset 5fc5918e5905 (bug 1613705)
Backed out changeset a7aeae7afd49 (bug 1613705)
Backed out changeset 5d61617a5402 (bug 1613705)
Backed out changeset 85bf98573899 (bug 1613705)
Backed out changeset 175af8a1b8c2 (bug 1613705)
Backed out changeset 93fcb23d7898 (bug 1613705)
Backed out changeset 595529cd906f (bug 1613705)
Backed out changeset 9f3e2963d925 (bug 1613705)
Backed out changeset 442289058933 (bug 1613705)
Backed out changeset fc3b9acb0e81 (bug 1613705)
Backed out changeset 408983c64f7f (bug 1613705)
Backed out changeset 08b637fc3fcd (bug 1613705)
Backed out changeset 6ef0aafd2db0 (bug 1613705)
Backed out changeset d88b294e0a5e (bug 1613705)
Backed out changeset e6bebff87544 (bug 1613705)
2021-08-03 12:36:01 +03:00
Zibi Braniecki 36d143e8ba Bug 1613705 - [localization] part9: Update DOMLocalization to match Localization constructor. r=nika,emilio
Depends on D113691

Differential Revision: https://phabricator.services.mozilla.com/D113692
2021-08-03 05:52:03 +00:00
Cosmin Sabou 3564c330b3 Backed out 11 changesets (bug 1613705) for several test failures. CLOSED TREE
Backed out changeset 4e690882b6af (bug 1613705)
Backed out changeset 302e7a75affc (bug 1613705)
Backed out changeset 626b40e3aad1 (bug 1613705)
Backed out changeset 1cbab987bb7d (bug 1613705)
Backed out changeset 2213917abb30 (bug 1613705)
Backed out changeset c89aa0375690 (bug 1613705)
Backed out changeset 6466027c5767 (bug 1613705)
Backed out changeset 6c188c4b38bf (bug 1613705)
Backed out changeset 8d0c087b9896 (bug 1613705)
Backed out changeset 3404fd6725f1 (bug 1613705)
Backed out changeset c9cfbba15d90 (bug 1613705)
2021-08-02 14:04:29 +03:00
Zibi Braniecki 458a2494df Bug 1613705 - [localization] part9: Update DOMLocalization to match Localization constructor. r=nika,emilio
Depends on D113691

Differential Revision: https://phabricator.services.mozilla.com/D113692
2021-08-02 09:54:10 +00:00
Nika Layzell fdaf413fa3 Bug 1586830 - Part 1: Ensure IsInitialDocument is set earlier and consistently on WindowGlobalParent, r=smaug
This makes sure to clear and set the value more consistently when replacing
documents within a WindowGlobal, and makes sure to include the relevant flag in
the initializer.

In addition, the place where the flag is set is moved ahead to happen before
the call to `Embed` so that the information is ready before the window is
created.

Differential Revision: https://phabricator.services.mozilla.com/D119815
2021-07-14 15:51:20 +00:00
Olli Pettay 6c11c7aad1 Bug 1710687, null check mDocShell before using it, r=peterv
The patch is based on code inspection. SizeShell may run scripts
https://searchfox.org/mozilla-central/rev/cecdac0aa5733fee515a166b6e31e38cc58abf32/xpfe/appshell/AppWindow.cpp#1180,1182

The patch is very conservative. It keeps returning success code in the cases where it would return such without the patch and only
adds null check right before accessing mDocShell. mDebuting value stays false after the method call.

Differential Revision: https://phabricator.services.mozilla.com/D115249
2021-05-25 12:25:41 +00:00
Edgar Chen 20a141de1f Bug 1706316 - Part 2: Remove nsIBaseWindow::setFocus; r=hsivonen
Depends on D112739

Differential Revision: https://phabricator.services.mozilla.com/D112740
2021-05-10 20:05:12 +00:00
Edgar Chen 45da1c12ad Bug 1706316 - Part 1: Remove nsIEmbeddingSiteWindow::setFocus; r=hsivonen
Differential Revision: https://phabricator.services.mozilla.com/D112739
2021-05-10 20:05:12 +00:00
Csoregi Natalia f20340f115 Backed out changeset 49744f943e16 (bug 1682136) for putting browser window partially behind left and top taskbars on older Windows versions (bug 1705504). 2021-04-18 11:32:17 +03:00
Doug Thayer 23378a0226 Bug 1704853 - Disable skeleton UI on non-default density r=emalysz
This is a little more than we need to disable it, but I figure we'll want to
support different UI densities in the skeleton UI long term.

Differential Revision: https://phabricator.services.mozilla.com/D111906
2021-04-15 22:58:19 +00:00
Csoregi Natalia 1d1158f8b5 Backed out changeset 95865502de4b (bug 1704853) for causing bustage on AppWindow.cpp. CLOSED TREE 2021-04-16 01:47:57 +03:00
Doug Thayer c632b8a57d Bug 1704853 - Disable skeleton UI on non-default density r=emalysz
This is a little more than we need to disable it, but I figure we'll want to
support different UI densities in the skeleton UI long term.

Differential Revision: https://phabricator.services.mozilla.com/D111906
2021-04-15 22:10:43 +00:00
Neil Deakin 54687b47ef Bug 1701668, remove nsIWebBrowserChrome3 interface, r=kmag
Differential Revision: https://phabricator.services.mozilla.com/D110103
2021-04-06 18:52:47 +00:00
Neil Deakin 54284e502d Bug 1701668, remove shouldLoadURI and shouldLoadURIInThisProcess methods now that all implementers return true, r=kmag
Differential Revision: https://phabricator.services.mozilla.com/D110101
2021-04-06 18:52:46 +00:00
Masatoshi Kimura c6dccb4a09 Bug 1682136 - Allow slop when the window position is persistent and it has no parent. r=xpcom-reviewers,nika
Differential Revision: https://phabricator.services.mozilla.com/D109708
2021-03-29 21:41:07 +00:00
harry 036ded43ac Bug 1699506 - Part 1 - Add a NSTitlebarAccessoryViewController to ToolbarWindow to track when the titlebar is shown in fullscreen. r=mac-reviewers,mstange
Differential Revision: https://phabricator.services.mozilla.com/D106846
2021-03-18 20:20:39 +00:00
Agi Sferro 111343732d Bug 1694481 - Remove unused code from exthandler/android. r=droeh,esawin
Differential Revision: https://phabricator.services.mozilla.com/D106182
2021-03-10 22:43:08 +00:00
Gerald Squelart 2416d881e2 Bug 1691589 - Reduce reliance on GeckoProfiler.h when only labels (and maybe markers) are needed - r=necko-reviewers,geckoview-reviewers,sg,agi,florian
There are no code changes, only #include changes.
It was a fairly mechanical process: Search for all "AUTO_PROFILER_LABEL", and in each file, if only labels are used, convert "GeckoProfiler.h" into "ProfilerLabels.h" (or just add that last one where needed).
In some files, there were also some marker calls but no other profiler-related calls, in these cases "GeckoProfiler.h" was replaced with both "ProfilerLabels.h" and "ProfilerMarkers.h", which still helps in reducing the use of the all-encompassing "GeckoProfiler.h".

Differential Revision: https://phabricator.services.mozilla.com/D104588
2021-02-16 04:44:19 +00:00
Markus Stange 3866ebf163 Bug 1691213 - DeCOMtaminate nsINativeMenuService and rename it to mozilla::widget::NativeMenuSupport. r=spohl
Differential Revision: https://phabricator.services.mozilla.com/D104311
2021-02-11 19:43:58 +00:00
Emma Malysz 3e25955d29 Bug 1689437, respect bookmarks.toolbars.bookmarks pref values to display bookmarks toolbar in skeleton UI r=dthayer
Differential Revision: https://phabricator.services.mozilla.com/D103358
2021-02-02 20:32:51 +00:00
Doug Thayer bfdaa1612c Bug 1686301 - Report errors in skeleton UI via telemetry r=mconley,emalysz
This is, for the most part, just a large refactor of the skeleton UI stuff to
support coarse-grained error reporting via telemetry. There are a few slight
changes in how we handle some errors. For example, if CreateWindow fails, we
will now bail out and report the failure. The flow for the happy path, however,
should remain unchanged.

Differential Revision: https://phabricator.services.mozilla.com/D102098
2021-01-26 16:10:20 +00:00
Emma Malysz 471404aa23 Bug 1686374, adjust margins if bookmarks toolbar is shown r=dthayer
Differential Revision: https://phabricator.services.mozilla.com/D101647
2021-01-22 20:59:21 +00:00
Mike Conley 43cabec511 Bug 1568133 - Wait to load MacOS app menu until l10n is ready. r=mstange
Original patch by Brendan Dahl <bdahl@mozilla.com>.

The change to nsCocoaWindow appears to be necessary because the nsMenuBarX
only seems to get created _after_ nsCocoaWindow::paintMenubarForWindow runs
for the created window, which is too late to Paint the native menu bar, but
also happens before nsCocoaWindow::sendToplevelActivateEvents runs, which
is too early for the nsCocoaWindow::SetMenuBar code's check for
toplevelActiveState on the WindowDelegate to return true.

So instead of checking for the toplevelActiveState, we now check if the
window for the newly created nsMenuBarX is the main window, and if so,
then we Paint it.

Differential Revision: https://phabricator.services.mozilla.com/D46202
2021-01-18 18:25:51 +00:00
Emma Malysz 3fa05e5db6 Bug 1671603: display skeleton ui elements in correct position when RTL is enabled r=dthayer
Stores the value of intl.uidirection in the registry

Differential Revision: https://phabricator.services.mozilla.com/D99559
2020-12-22 17:22:07 +00:00
Emilio Cobos Álvarez 3987c781d0 Bug 1635914 - Move active flag handling explicitly to BrowsingContext. r=nika
And have it mirror in the parent process more automatically.

The docShellIsActive setter in the browser-custom-element side needs to
be there rather than in the usual DidSet() calls because the
AsyncTabSwitcher code relies on getting an exact amount of notifications
as response to that specific setter. Not pretty, but...

BrowserChild no longer sets IsActive() on the docshell itself for OOP
iframes. This fixes bug 1679521. PresShell activeness is used to
throttle rAF as well, which handles OOP iframes nicely as well.

Differential Revision: https://phabricator.services.mozilla.com/D96072
2020-12-11 15:43:19 +00:00
Emma Malysz 3f3b02f520 Bug 1677185, update margins in skeleton UI if menubar is shown r=dthayer
The menubar is permanently shown if autohide is false. If that is the case, we
insert space above the tab and ensure the tab does not have a left margin.
It's height can change, so we store the height in our registry.

Differential Revision: https://phabricator.services.mozilla.com/D97195
2020-12-10 20:29:03 +00:00
Simon Giesecke e06a2d56fc Bug 1680269 - Fix build when building without MOZ_GECKO_PROFILER. r=gerald
Differential Revision: https://phabricator.services.mozilla.com/D99063
2020-12-09 08:58:06 +00:00
Andrew McCreight 9cc98c8bf5 Bug 1539948, part 2 - Make nsIWebNavigation and nsIWindowlessBrowser builtinclass. r=nika,Gijs
These two interfaces contain nostdcall methods, so they should be marked
builtinclass.

There is a JS implementation of nsIWebNavigation in RemoteWebNavigation,
but it appears to never be passed into C++, so it doesn't need to be
made into a "real" implementation of nsIWebNavigation that can be passed
through XPConnect.

Differential Revision: https://phabricator.services.mozilla.com/D98862
2020-12-09 02:40:14 +00:00
Razvan Maries 35ccea0325 Backed out 3 changesets (bug 1539948) for build bustages on nsISocketTransport.h. CLOSED TREE
Backed out changeset 81bed88d0adf (bug 1539948)
Backed out changeset 8bf24bdf431f (bug 1539948)
Backed out changeset ef4e49b3701d (bug 1539948)
2020-12-09 02:47:52 +02:00
Andrew McCreight a7c299978d Bug 1539948, part 2 - Make nsIWebNavigation and nsIWindowlessBrowser builtinclass. r=nika,Gijs
These two interfaces contain nostdcall methods, so they should be marked
builtinclass.

There is a JS implementation of nsIWebNavigation in RemoteWebNavigation,
but it appears to never be passed into C++, so it doesn't need to be
made into a "real" implementation of nsIWebNavigation that can be passed
through XPConnect.

Differential Revision: https://phabricator.services.mozilla.com/D98862
2020-12-08 21:22:31 +00:00
Simon Giesecke d10d03d076 Bug 1676365 - Move SpinEventLoopUntil to separate header. r=#xpcom-reviewers
Differential Revision: https://phabricator.services.mozilla.com/D96556

Depends on D96554
2020-11-23 16:10:41 +00:00
Simon Giesecke 971b645fe3 Bug 1660470 - Add missing include directives/forward declarations. r=nika
Differential Revision: https://phabricator.services.mozilla.com/D87865
2020-11-23 16:21:38 +00:00
Henri Sivonen 96ae695458 Bug 1618386 - Add action ids to filter out stale active browsing context updates. r=nika
Differential Revision: https://phabricator.services.mozilla.com/D94969
2020-11-16 19:16:20 +00:00
Nika Layzell 9ff27adca3 Bug 1671983 - Part 1: Remove now-unused process switching shouldLoadURI methods, r=annyG,geckoview-reviewers,snorp
These methods are no longer necessary, as all loads which can trigger process
switches now go through DocumentChannel.

The shouldLoadURI methods on nsIWebBrowserChrome3 are unfortunately still
necessary as they're used by the disabled-by-default "Single-Site Browser"
feature. In the future this may be possible to clean-up.

Differential Revision: https://phabricator.services.mozilla.com/D94638
2020-11-12 18:00:53 +00:00
Emma Malysz 21991a311d Bug 1670957, add placeholder rectangles for toolbarbuttons and display in skeleton UI r=dthayer,smaug,Gijs
If a searchbar is present, draw that similar to a urlbar.
This also changes how we store the urlbar, as we know will use our custom struct
to cleanly store the width and height.

Differential Revision: https://phabricator.services.mozilla.com/D95029
2020-11-10 16:48:10 +00:00
Razvan Maries 10425eddfc Backed out 7 changesets (bug 1658084, bug 1671983) for perma failures on browser_async_remove_tab.js and browser_e10s_chrome_process.js. CLOSED TREE
Backed out changeset 2e6309c1cdbd (bug 1658084)
Backed out changeset 99aafd9304ef (bug 1671983)
Backed out changeset 80280b85280a (bug 1671983)
Backed out changeset 008db2659002 (bug 1671983)
Backed out changeset 32bd45c7fe3a (bug 1671983)
Backed out changeset 56e227e6580c (bug 1671983)
Backed out changeset a404f809f79d (bug 1671983)
2020-11-04 04:23:47 +02:00
Nika Layzell b20d2f0f1b Bug 1671983 - Part 1: Remove now-unused process switching shouldLoadURI methods, r=annyG,geckoview-reviewers,snorp
These methods are no longer necessary, as all loads which can trigger process
switches now go through DocumentChannel.

The shouldLoadURI methods on nsIWebBrowserChrome3 are unfortunately still
necessary as they're used by the disabled-by-default "Single-Site Browser"
feature. In the future this may be possible to clean-up.

Differential Revision: https://phabricator.services.mozilla.com/D94638
2020-11-04 00:55:23 +00:00
Doug Thayer 30478629cf Bug 1666874 - Support maximized windows for skeleton UI r=agashlin
Most of this patch is a dance to avoid size flickering of the skeleton UI
window. We change all Resize/Move/SetSizeMode calls from before the first
nsWindow::Show call. Normally those have no effect, since the window isn't
shown yet, and if the window is not maximized, they typically match the
sizes we've gotten out of the registry anyway. However, if we are maximized,
then they produce a lot of visual noise. We can however achieve the desired
effect by just calling SetWindowPlacement.

Similarly, we switch the window styles of the skeleton UI window to match those
of the toplevel Windows window, and adjust the client rect from our window proc
in a way that matches the adjustments in nsWindow in the WM_NCCALCSIZE handler.
We do this because otherwise we get a flicker as soon as we change the styles
and nonclient margins as the fake chrome pops up and then back down.

Lastly we also change the extended window styles so that they match. We
historically added WS_EX_TOOLWINDOW here to hide the toolbar entry, because it
would otherwise switch out to a new toolbar entry when we changed the window
styles. However since our new styles match, we no longer need to do this. It
was also causing the maximized window to paint over the Windows taskbar.

Differential Revision: https://phabricator.services.mozilla.com/D93534
2020-10-29 19:04:02 +00:00
Butkovits Atila 304bfab038 Backed out 2 changesets (bug 1666874, bug 1665455) for causing bustage on PreXULSkeletonUI.cpp. CLOSED TREE
Backed out changeset 967c4cf56fd2 (bug 1666874)
Backed out changeset e46238e6aabf (bug 1665455)
2020-10-29 16:57:35 +02:00
Doug Thayer 38c0351ae3 Bug 1666874 - Support maximized windows for skeleton UI r=agashlin
Most of this patch is a dance to avoid size flickering of the skeleton UI
window. We change all Resize/Move/SetSizeMode calls from before the first
nsWindow::Show call. Normally those have no effect, since the window isn't
shown yet, and if the window is not maximized, they typically match the
sizes we've gotten out of the registry anyway. However, if we are maximized,
then they produce a lot of visual noise. We can however achieve the desired
effect by just calling SetWindowPlacement.

Similarly, we switch the window styles of the skeleton UI window to match those
of the toplevel Windows window, and adjust the client rect from our window proc
in a way that matches the adjustments in nsWindow in the WM_NCCALCSIZE handler.
We do this because otherwise we get a flicker as soon as we change the styles
and nonclient margins as the fake chrome pops up and then back down.

Lastly we also change the extended window styles so that they match. We
historically added WS_EX_TOOLWINDOW here to hide the toolbar entry, because it
would otherwise switch out to a new toolbar entry when we changed the window
styles. However since our new styles match, we no longer need to do this. It
was also causing the maximized window to paint over the Windows taskbar.

Differential Revision: https://phabricator.services.mozilla.com/D93534
2020-10-29 14:09:54 +00:00
Emma Malysz 7529feec30 Bug 1665460: save urlbar position to registry and display in skeleton UI r=dthayer,smaug
If the urlbar is zoomed (defined by attribute breakout-extend), then we
scale it down to the unfocused coordinate values.

Differential Revision: https://phabricator.services.mozilla.com/D92303
2020-10-27 15:53:38 +00:00
Ricky Stewart 02a7b4ebdf Bug 1654103: Standardize on Black for Python code in `mozilla-central`.
Allow-list all Python code in tree for use with the black linter, and re-format all code in-tree accordingly.

To produce this patch I did all of the following:

1. Make changes to tools/lint/black.yml to remove include: stanza and update list of source extensions.

2. Run ./mach lint --linter black --fix

3. Make some ad-hoc manual updates to python/mozbuild/mozbuild/test/configure/test_configure.py -- it has some hard-coded line numbers that the reformat breaks.

4. Make some ad-hoc manual updates to `testing/marionette/client/setup.py`, `testing/marionette/harness/setup.py`, and `testing/firefox-ui/harness/setup.py`, which have hard-coded regexes that break after the reformat.

5. Add a set of exclusions to black.yml. These will be deleted in a follow-up bug (1672023).

# ignore-this-changeset

Differential Revision: https://phabricator.services.mozilla.com/D94045
2020-10-26 18:34:53 +00:00
Bogdan Tara da1098d4aa Backed out 10 changesets (bug 1654103, bug 1672023, bug 1518999) for PanZoomControllerTest.touchEventForResult gv-junit failures CLOSED TREE
Backed out changeset ff3fb0b4a512 (bug 1672023)
Backed out changeset e7834b600201 (bug 1654103)
Backed out changeset 807893ca8069 (bug 1518999)
Backed out changeset 13e6b92440e9 (bug 1518999)
Backed out changeset 8b2ac5a6c98a (bug 1518999)
Backed out changeset 575748295752 (bug 1518999)
Backed out changeset 65f07ce7b39b (bug 1518999)
Backed out changeset 4bb80556158d (bug 1518999)
Backed out changeset 8ac8461d7bd7 (bug 1518999)
Backed out changeset e8ba13ee17f5 (bug 1518999)
2020-10-24 03:36:18 +03:00
Ricky Stewart c0cea3b0fa Bug 1654103: Standardize on Black for Python code in `mozilla-central`. r=remote-protocol-reviewers,marionette-reviewers,webdriver-reviewers,perftest-reviewers,devtools-backward-compat-reviewers,jgilbert,preferences-reviewers,sylvestre,maja_zf,webcompat-reviewers,denschub,ntim,whimboo,sparky
Allow-list all Python code in tree for use with the black linter, and re-format all code in-tree accordingly.

To produce this patch I did all of the following:

1. Make changes to tools/lint/black.yml to remove include: stanza and update list of source extensions.

2. Run ./mach lint --linter black --fix

3. Make some ad-hoc manual updates to python/mozbuild/mozbuild/test/configure/test_configure.py -- it has some hard-coded line numbers that the reformat breaks.

4. Make some ad-hoc manual updates to `testing/marionette/client/setup.py`, `testing/marionette/harness/setup.py`, and `testing/firefox-ui/harness/setup.py`, which have hard-coded regexes that break after the reformat.

5. Add a set of exclusions to black.yml. These will be deleted in a follow-up bug (1672023).

# ignore-this-changeset

Differential Revision: https://phabricator.services.mozilla.com/D94045
2020-10-23 20:40:42 +00:00
Dorel Luca 1ff59cb7a3 Backed out changeset 7558c8821a07 (bug 1654103) for multiple failures. CLOSED TREE 2020-10-22 03:51:06 +03:00
Ricky Stewart 50762dacab Bug 1654103: Standardize on Black for Python code in `mozilla-central`. r=remote-protocol-reviewers,marionette-reviewers,webdriver-reviewers,perftest-reviewers,devtools-backward-compat-reviewers,jgilbert,preferences-reviewers,sylvestre,maja_zf,webcompat-reviewers,denschub,ntim,whimboo,sparky
Allow-list all Python code in tree for use with the black linter, and re-format all code in-tree accordingly.

To produce this patch I did all of the following:

1. Make changes to tools/lint/black.yml to remove include: stanza and update list of source extensions.

2. Run ./mach lint --linter black --fix

3. Make some ad-hoc manual updates to python/mozbuild/mozbuild/test/configure/test_configure.py -- it has some hard-coded line numbers that the reformat breaks.

4. Add a set of exclusions to black.yml. These will be deleted in a follow-up bug (1672023).

# ignore-this-changeset

Differential Revision: https://phabricator.services.mozilla.com/D94045
2020-10-21 21:27:27 +00:00
Edgar Chen 2a18e0fc77 Bug 1667081 - Part 3: Remove windowLowered in nsIFocusManager; r=hsivonen
And make nsFocusManager::WindowLowered just returning void given all caller
doesn't actaully check the return value.

Differential Revision: https://phabricator.services.mozilla.com/D91289
2020-09-29 07:21:34 +00:00
Edgar Chen 6bf9a2e159 Bug 1667081 - Part 2: Remove windowRaised in nsIFocusManager; r=hsivonen
And make nsFocusManager::WindowRaised just returning void given all caller
doesn't actaully check the return value.

Differential Revision: https://phabricator.services.mozilla.com/D91288
2020-09-29 07:21:22 +00:00
Bogdan Tara 8f6c53bdf5 Backed out 9 changesets (bug 1667081) for assertion failure on nsFocusManager CLOSED TREE
Backed out changeset 156ab3eba505 (bug 1667081)
Backed out changeset 2e37f347082c (bug 1667081)
Backed out changeset 8f59cef879ae (bug 1667081)
Backed out changeset 1298ff140218 (bug 1667081)
Backed out changeset 91342c822425 (bug 1667081)
Backed out changeset aafb1878c590 (bug 1667081)
Backed out changeset 2252e975f0d7 (bug 1667081)
Backed out changeset c3bac5f407d2 (bug 1667081)
Backed out changeset b1e6e81396ae (bug 1667081)
2020-09-28 20:02:52 +03:00
Edgar Chen 0a849192c3 Bug 1667081 - Part 3: Remove windowLowered in nsIFocusManager; r=hsivonen
This patch also does following changes,
- Assert aWindow instead of early return given all caller passes a non-null window.
- Make it returning void given all caller doesn't actaully check the return value.

Differential Revision: https://phabricator.services.mozilla.com/D91289
2020-09-28 14:04:37 +00:00
Edgar Chen a60331bed5 Bug 1667081 - Part 2: Remove windowRaised in nsIFocusManager; r=hsivonen
This patch also does following changes,
- Assert aWindow instead of early return given all caller passes a non-null window.
- Make it returning void given all caller doesn't actaully check the return value.

Differential Revision: https://phabricator.services.mozilla.com/D91288
2020-09-28 14:04:25 +00:00
Doug Thayer acd22d7041 Bug 1665453 - Rename EarlyBlankWindow to PreXULSkeletonUI r=agashlin
This is just a more correct name for what's going on.

Differential Revision: https://phabricator.services.mozilla.com/D91004
2020-09-24 14:25:56 +00:00
Doug Thayer cb7d215459 Bug 1665456 - Ensure window focus received for skele UI window r=mhowell
Because we create our initial window much earlier, we do not receive the
initial activation and focus messages in the same way. Accordingly, we
need to refocus the window once everything is properly set up to handle
it.

Regarding testing, the intent is that this will be covered by existing
tests, since this is not intended to be a behavioral change for window
focus. It is not covered by tests currently only because the skele UI
is disabled by default.

Depends on D90467

Differential Revision: https://phabricator.services.mozilla.com/D90607
2020-09-18 16:40:30 +00:00
Doug Thayer fa7b10106a Bug 1656526 - Show blank window prior to loading xul on Windows r=mhowell
See bug for justification. This patch aims to display a blank window prior to
loading/prefetching xul.dll. It also has a placeholder for drawing a
skeleton UI into that window. Note that this is disabled by default based on
a registry value, as there are still kinks to work out (for instance, what
happens if we aren't actually going to display a window, because, say, Firefox
is already running.) This just gives a basic implementation to dogfood, and
facilitates distributing work across multiple contributors.

Onto the details. The patch achieves its goal by creating a window and
assigning its handle to a static variable, which will be consumed inside
nsWindow::Create by the first toplevel window we want to make. nsWindow::Create
will take ownership of the window handle, restyle it to its own liking, and
then proceed as if everything is normal and it had created the window itself.

Differential Revision: https://phabricator.services.mozilla.com/D86263
2020-09-15 14:50:19 +00:00
Dorel Luca 634b687351 Backed out 4 changesets (bug 1656526) for Browser-chrome failures in toolkit/xre/test/browser_checkdllblockliststate.js. CLOSED TREE
Backed out changeset 24648c48a49c (bug 1656526)
Backed out changeset 472b724994eb (bug 1656526)
Backed out changeset 6fbb7e7ac121 (bug 1656526)
Backed out changeset 88ff36a4bcfb (bug 1656526)
2020-09-11 23:17:23 +03:00
Doug Thayer efe700e222 Bug 1656526 - Show blank window prior to loading xul on Windows r=mhowell
See bug for justification. This patch aims to display a blank window prior to
loading/prefetching xul.dll. It also has a placeholder for drawing a
skeleton UI into that window. Note that this is disabled by default based on
a registry value, as there are still kinks to work out (for instance, what
happens if we aren't actually going to display a window, because, say, Firefox
is already running.) This just gives a basic implementation to dogfood, and
facilitates distributing work across multiple contributors.

Onto the details. The patch achieves its goal by creating a window and
assigning its handle to a static variable, which will be consumed inside
nsWindow::Create by the first toplevel window we want to make. nsWindow::Create
will take ownership of the window handle, restyle it to its own liking, and
then proceed as if everything is normal and it had created the window itself.

Differential Revision: https://phabricator.services.mozilla.com/D86263
2020-09-11 14:12:00 +00:00
Kris Maglione 5f2d674982 Bug 1650257: Part 1 - Stop discarding BCs from the parent on WindowGlobal destruction. r=nika
Differential Revision: https://phabricator.services.mozilla.com/D87485
2020-08-31 18:51:45 +00:00
Emilio Cobos Álvarez 044b3c4332 Bug 1636728 - Centralize printing entry points in nsGlobalWindowOuter, and move cloning out of nsPrintJob. r=jwatt,geckoview-reviewers,smaug,agi
This centralizes our print and preview setup in nsGlobalWindowOuter so
that we never re-clone a clone, and so that we reuse the window.open()
codepath to create the browsing context to clone into.

For window.print, for both old print dialog / silent printing and new
print preview UI, we now create a hidden browser (as in with visibility:
collapse, which takes no space but still gets a layout box).

 * In the modern UI case, this browser is swapped with the actual print
   preview clone, and the UI takes care of removing the browser.

 * In the print dialog / silent printing case, the printing code calls
   window.close() from nsDocumentViewer::OnDonePrinting().

 * We don't need to care about the old print preview UI for this case
   because it can't be open from window.print().

We need to fall back to an actual window when there's no
nsIBrowserDOMWindow around for WPT print tests and the like, which don't
have one. That seems fine, we could special-case this code path more if
needed but it doesn't seem worth it.

Differential Revision: https://phabricator.services.mozilla.com/D87063
2020-08-25 17:45:12 +00:00
Razvan Maries 6742cf83d7 Backed out 2 changesets (bug 1656526) for build bustages on EarlyBlankWindow.cpp. CLOSED TREE
Backed out changeset b6d3b254ae8c (bug 1656526)
Backed out changeset abdc9c22078c (bug 1656526)
2020-08-18 19:10:37 +03:00
Doug Thayer b5e46bb95c Bug 1656526 - Show blank window prior to loading xul on Windows r=mhowell
See bug for justification. This patch aims to display a blank window prior to
loading/prefetching xul.dll. It also has a placeholder for drawing a
skeleton UI into that window. Note that this is disabled by default based on
a registry value, as there are still kinks to work out (for instance, what
happens if we aren't actually going to display a window, because, say, Firefox
is already running.) This just gives a basic implementation to dogfood, and
facilitates distributing work across multiple contributors.

Onto the details. The patch achieves its goal by creating a window and
assigning its handle to a static variable, which will be consumed inside
nsWindow::Create by the first toplevel window we want to make. nsWindow::Create
will take ownership of the window handle, restyle it to its own liking, and
then proceed as if everything is normal and it had created the window itself.

Differential Revision: https://phabricator.services.mozilla.com/D86263
2020-08-18 15:31:28 +00:00
Nika Layzell 1c71a222fc Bug 1653729 - Part 1: Generalize do_QueryActor API, r=kmag
This changes the set of types which can be passed as the second argument to
do_QueryActor to ones which can be unambiguously converted to a JSActorManager,
and combines nsCOMPtr_helper implementations.

Differential Revision: https://phabricator.services.mozilla.com/D84067
2020-08-04 21:34:29 +00:00
Edgar Chen 86341ec4ef Bug 1653214 - Part 2: Remove nsIBaseWindow::Create; r=nika
Differential Revision: https://phabricator.services.mozilla.com/D83767
2020-07-16 20:42:20 +00:00
Edgar Chen beeae4cb08 Bug 1653214 - Part 1: Merge implementations of nsDocShell::Create into nsDocShell::InitWindow; r=nika
Differential Revision: https://phabricator.services.mozilla.com/D83766
2020-07-16 20:42:02 +00:00
Edgar Chen 992cce2a73 Bug 1653124 - Use nsDocShell directly in AppWindow; r=nika
Differential Revision: https://phabricator.services.mozilla.com/D83714
2020-07-16 20:41:45 +00:00
Xidorn Quan f62edc3be9 Bug 1350875 part 6 - Wait for window resize for one frame after window goes fullscreen. r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D68682
2020-07-15 12:21:45 +00:00
Kashav Madan c552df8948 Bug 1580811 - Make the ContentPage browser work with out-of-process frames, r=nika,zombie
Differential Revision: https://phabricator.services.mozilla.com/D80084
2020-07-10 13:40:51 +00:00
Butkovits Atila b8cf7098a8 Backed out 3 changesets (bug 1580811) for failures at test_ext_contentscript_xorigin_frame.js. CLOSED TREE
Backed out changeset 7733de7d4f5a (bug 1580811)
Backed out changeset d18f8e821cc7 (bug 1580811)
Backed out changeset f9c8318e3c01 (bug 1580811)
2020-07-10 03:07:12 +03:00
Kashav Madan 5e7059c4e5 Bug 1580811 - Make the ContentPage browser work with out-of-process frames, r=nika,zombie
Differential Revision: https://phabricator.services.mozilla.com/D80084
2020-07-09 21:34:38 +00:00
Kris Maglione 6a39211860 Bug 1464542: Part 3b - Add existing Services.jsm registrations to the new services cache. r=mccr8,geckoview-reviewers,agi
Differential Revision: https://phabricator.services.mozilla.com/D81419
2020-07-09 21:42:25 +00:00
Csoregi Natalia b355fcc4bf Backed out 6 changesets (bug 1464542) for xpcshell failures on test_Services.js. CLOSED TREE
Backed out changeset b50af9005851 (bug 1464542)
Backed out changeset 9d3a0ea2cf65 (bug 1464542)
Backed out changeset 71c3475fcbc2 (bug 1464542)
Backed out changeset 51ff93220a95 (bug 1464542)
Backed out changeset e84de1547c09 (bug 1464542)
Backed out changeset bbecc16d08eb (bug 1464542)
2020-07-09 23:19:26 +03:00
Kris Maglione d09458dc51 Bug 1464542: Part 3b - Add existing Services.jsm registrations to the new services cache. r=mccr8,geckoview-reviewers,agi
Differential Revision: https://phabricator.services.mozilla.com/D81419
2020-07-09 17:59:16 +00:00
Simon Giesecke cd8b8939b9 Bug 1648010 - Replace uses of NS_LITERAL_STRING/NS_LITERAL_CSTRING macros by _ns literals. r=geckoview-reviewers,jgilbert,agi,hsivonen,froydnj
Differential Revision: https://phabricator.services.mozilla.com/D80860
2020-07-01 08:29:29 +00:00
Eden Chuang a383fd6b63 Bug 1637035 - Do not inherit COEP from opener for non-http or non-initial-about:blank documents r=nika
Differential Revision: https://phabricator.services.mozilla.com/D80414
2020-06-25 02:14:29 +00:00
Gijs Kruitbosch 222e2d1158 Bug 1644863 - fix trailing whitespace in cross-tree tests, r=emilio,marionette-reviewers,whimboo
Differential Revision: https://phabricator.services.mozilla.com/D79202
2020-06-17 22:45:31 +00:00
Simon Giesecke ad4f33cc52 Bug 1645339 - Use range-based for with nsTObserverArray in xpfe. r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D79505
2020-06-16 10:16:46 +00:00
Nika Layzell cde53b3bec Bug 1508306 - Part 1: Migate the Large-Allocation handler to DocumentLoadListener, r=mattwoodrow,necko-reviewers,geckoview-reviewers,agi,valentin
This removes the diagnostic warnings which used to be logged when the
Large-Allocation header was present, but failed to switch into a
Large-Allocation process. Due to the low adoption of the header, this shouldn't
be too large of a problem, but we can look into re-adding the diagnostics if
needed in the future.

The new codepath no longer performs multiple network requests for
Large-Allocation resources, and now relies on the battle-tested
DocumentLoadListener codepath for process switching.

Differential Revision: https://phabricator.services.mozilla.com/D78998
2020-06-15 23:24:07 +00:00
Nika Layzell c867d0930c Bug 1640019 - Part 7: Remove the unused 'navigateAndRestoreByIndex' method, r=Gijs
This method was used by GroupedSHistory for prerendering, and was missed when we
ripped out the incomplete code.

Differential Revision: https://phabricator.services.mozilla.com/D78975
2020-06-15 23:24:02 +00:00