Pier Angelo Vendrame pushed to branch base-browser-102.7.0esr-12.5-1 at The Tor Project / Applications / Tor Browser
Commits:
-
971383bf
by Henry Wilkes at 2023-02-08T10:24:49+00:00
-
2bbd2240
by Henry Wilkes at 2023-02-08T10:24:59+00:00
6 changed files:
- browser/app/profile/001-base-profile.js
- browser/components/BrowserGlue.jsm
- browser/components/newtab/AboutNewTabService.jsm
- browser/components/preferences/home.inc.xhtml
- browser/components/preferences/home.js
- browser/modules/HomePage.jsm
Changes:
... | ... | @@ -4,6 +4,11 @@ |
4 | 4 | // Use the OS locale by default (tor-browser#17400)
|
5 | 5 | pref("intl.locale.requested", "");
|
6 | 6 | |
7 | +// Home page and new tab is blank rather than Firefox Home (Activity Stream).
|
|
8 | +// tor-browser#31575 and tor-browser#30662
|
|
9 | +pref("browser.startup.homepage", "about:blank");
|
|
10 | +pref("browser.newtabpage.enabled", false);
|
|
11 | + |
|
7 | 12 | // Disable initial homepage notifications
|
8 | 13 | pref("browser.search.update", false);
|
9 | 14 | pref("startup.homepage_welcome_url", "");
|
... | ... | @@ -151,7 +156,6 @@ pref("services.sync.engine.passwords", false); |
151 | 156 | pref("services.sync.engine.prefs", false);
|
152 | 157 | pref("services.sync.engine.tabs", false);
|
153 | 158 | pref("extensions.getAddons.cache.enabled", false); // https://blog.mozilla.org/addons/how-to-opt-out-of-add-on-metadata-updates/
|
154 | -pref("browser.newtabpage.enabled", false);
|
|
155 | 159 | pref("browser.search.region", "US"); // The next two prefs disable GeoIP search lookups (#16254)
|
156 | 160 | pref("browser.search.geoip.url", "");
|
157 | 161 | pref("browser.fixup.alternate.enabled", false); // Bug #16783: Prevent .onion fixups
|
... | ... | @@ -18,7 +18,6 @@ const { AppConstants } = ChromeUtils.import( |
18 | 18 | );
|
19 | 19 | |
20 | 20 | XPCOMUtils.defineLazyModuleGetters(this, {
|
21 | - AboutNewTab: "resource:///modules/AboutNewTab.jsm",
|
|
22 | 21 | ActorManagerParent: "resource://gre/modules/ActorManagerParent.jsm",
|
23 | 22 | AddonManager: "resource://gre/modules/AddonManager.jsm",
|
24 | 23 | AppMenuNotifications: "resource://gre/modules/AppMenuNotifications.jsm",
|
... | ... | @@ -223,28 +222,6 @@ let JSWINDOWACTORS = { |
223 | 222 | remoteTypes: ["privilegedabout"],
|
224 | 223 | },
|
225 | 224 | |
226 | - AboutNewTab: {
|
|
227 | - parent: {
|
|
228 | - moduleURI: "resource:///actors/AboutNewTabParent.jsm",
|
|
229 | - },
|
|
230 | - child: {
|
|
231 | - moduleURI: "resource:///actors/AboutNewTabChild.jsm",
|
|
232 | - events: {
|
|
233 | - DOMContentLoaded: {},
|
|
234 | - pageshow: {},
|
|
235 | - visibilitychange: {},
|
|
236 | - },
|
|
237 | - },
|
|
238 | - // The wildcard on about:newtab is for the ?endpoint query parameter
|
|
239 | - // that is used for snippets debugging. The wildcard for about:home
|
|
240 | - // is similar, and also allows for falling back to loading the
|
|
241 | - // about:home document dynamically if an attempt is made to load
|
|
242 | - // about:home?jscache from the AboutHomeStartupCache as a top-level
|
|
243 | - // load.
|
|
244 | - matches: ["about:home*", "about:welcome", "about:newtab*"],
|
|
245 | - remoteTypes: ["privilegedabout"],
|
|
246 | - },
|
|
247 | - |
|
248 | 225 | AboutPlugins: {
|
249 | 226 | parent: {
|
250 | 227 | moduleURI: "resource:///actors/AboutPluginsParent.jsm",
|
... | ... | @@ -1576,8 +1553,6 @@ BrowserGlue.prototype = { |
1576 | 1553 | |
1577 | 1554 | // the first browser window has finished initializing
|
1578 | 1555 | _onFirstWindowLoaded: function BG__onFirstWindowLoaded(aWindow) {
|
1579 | - AboutNewTab.init();
|
|
1580 | - |
|
1581 | 1556 | TabCrashHandler.init();
|
1582 | 1557 | |
1583 | 1558 | ProcessHangMonitor.init();
|
... | ... | @@ -5785,12 +5760,8 @@ var AboutHomeStartupCache = { |
5785 | 5760 | return { pageInputStream: null, scriptInputStream: null };
|
5786 | 5761 | }
|
5787 | 5762 | |
5788 | - let state = AboutNewTab.activityStream.store.getState();
|
|
5789 | - return new Promise(resolve => {
|
|
5790 | - this._cacheDeferred = resolve;
|
|
5791 | - this.log.trace("Parent is requesting cache streams.");
|
|
5792 | - this._procManager.sendAsyncMessage(this.CACHE_REQUEST_MESSAGE, { state });
|
|
5793 | - });
|
|
5763 | + this.log.error("Activity Stream is disabled.");
|
|
5764 | + return { pageInputStream: null, scriptInputStream: null };
|
|
5794 | 5765 | },
|
5795 | 5766 | |
5796 | 5767 | /**
|
... | ... | @@ -420,20 +420,7 @@ class BaseAboutNewTabService { |
420 | 420 | * the newtab page has no effect on the result of this function.
|
421 | 421 | */
|
422 | 422 | get defaultURL() {
|
423 | - // Generate the desired activity stream resource depending on state, e.g.,
|
|
424 | - // "resource://activity-stream/prerendered/activity-stream.html"
|
|
425 | - // "resource://activity-stream/prerendered/activity-stream-debug.html"
|
|
426 | - // "resource://activity-stream/prerendered/activity-stream-noscripts.html"
|
|
427 | - return [
|
|
428 | - "resource://activity-stream/prerendered/",
|
|
429 | - "activity-stream",
|
|
430 | - // Debug version loads dev scripts but noscripts separately loads scripts
|
|
431 | - this.activityStreamDebug && !this.privilegedAboutProcessEnabled
|
|
432 | - ? "-debug"
|
|
433 | - : "",
|
|
434 | - this.privilegedAboutProcessEnabled ? "-noscripts" : "",
|
|
435 | - ".html",
|
|
436 | - ].join("");
|
|
423 | + return "about:blank";
|
|
437 | 424 | }
|
438 | 425 | |
439 | 426 | get welcomeURL() {
|
... | ... | @@ -33,7 +33,6 @@ |
33 | 33 | class="check-home-page-controlled"
|
34 | 34 | data-preference-related="browser.startup.homepage">
|
35 | 35 | <menupopup>
|
36 | - <menuitem value="0" data-l10n-id="home-mode-choice-default" />
|
|
37 | 36 | <menuitem value="2" data-l10n-id="home-mode-choice-custom" />
|
38 | 37 | <menuitem value="1" data-l10n-id="home-mode-choice-blank" />
|
39 | 38 | </menupopup>
|
... | ... | @@ -84,7 +83,6 @@ |
84 | 83 | Preferences so we need to handle setting the pref manually.-->
|
85 | 84 | <menulist id="newTabMode" flex="1" data-preference-related="browser.newtabpage.enabled">
|
86 | 85 | <menupopup>
|
87 | - <menuitem value="0" data-l10n-id="home-mode-choice-default" />
|
|
88 | 86 | <menuitem value="1" data-l10n-id="home-mode-choice-blank" />
|
89 | 87 | </menupopup>
|
90 | 88 | </menulist>
|
... | ... | @@ -380,10 +380,14 @@ var gHomePane = { |
380 | 380 | |
381 | 381 | if (controllingExtension && controllingExtension.id) {
|
382 | 382 | newValue = controllingExtension.id;
|
383 | - } else if (isDefault) {
|
|
384 | - newValue = this.HOME_MODE_FIREFOX_HOME;
|
|
385 | 383 | } else if (isBlank) {
|
384 | + // For base-browser, we want to check isBlank first since the default page
|
|
385 | + // is also the blank page, but we only have a menu option for
|
|
386 | + // HOME_MODE_BLANK, rather than HOME_MODE_FIREFOX_HOME.
|
|
387 | + // See tor-browser#41609.
|
|
386 | 388 | newValue = this.HOME_MODE_BLANK;
|
389 | + } else if (isDefault) {
|
|
390 | + newValue = this.HOME_MODE_FIREFOX_HOME;
|
|
387 | 391 | } else {
|
388 | 392 | newValue = this.HOME_MODE_CUSTOM;
|
389 | 393 | }
|
... | ... | @@ -21,7 +21,7 @@ XPCOMUtils.defineLazyModuleGetters(this, { |
21 | 21 | });
|
22 | 22 | |
23 | 23 | const kPrefName = "browser.startup.homepage";
|
24 | -const kDefaultHomePage = "about:home";
|
|
24 | +const kDefaultHomePage = "about:blank";
|
|
25 | 25 | const kExtensionControllerPref =
|
26 | 26 | "browser.startup.homepage_override.extensionControlled";
|
27 | 27 | const kHomePageIgnoreListId = "homepage-urls";
|