mirror of
https://github.com/pulse-browser/browser.git
synced 2024-09-11 20:47:49 +03:00
Update for firefox 116.0.2
This commit is contained in:
parent
f610330663
commit
eeba4b593e
10
gluon.json
10
gluon.json
@ -5,7 +5,7 @@
|
||||
"binaryName": "pulse-browser",
|
||||
"version": {
|
||||
"product": "firefox",
|
||||
"version": "115.0.1"
|
||||
"version": "116.0.2"
|
||||
},
|
||||
"buildOptions": {
|
||||
"generateBranding": true
|
||||
@ -15,7 +15,7 @@
|
||||
"platform": "github",
|
||||
"id": "uBlock0@raymondhill.net",
|
||||
"repo": "gorhill/uBlock",
|
||||
"version": "1.50.0",
|
||||
"version": "1.51.0",
|
||||
"fileGlob": "uBlock0_*.firefox(.signed)?.xpi"
|
||||
},
|
||||
"tabliss": {
|
||||
@ -93,10 +93,8 @@
|
||||
}
|
||||
},
|
||||
"license": {
|
||||
"ignoredFiles": [
|
||||
".*\\.json"
|
||||
],
|
||||
"ignoredFiles": [".*\\.json"],
|
||||
"licenseType": "MPL-2.0"
|
||||
},
|
||||
"updateHostname": "updates.pulsebrowser.app"
|
||||
}
|
||||
}
|
||||
|
@ -1,10 +1,10 @@
|
||||
diff --git a/browser/app/profile/firefox.js b/browser/app/profile/firefox.js
|
||||
index 56c8022ec4bbeda70e09c3b8780afcbf21ba0579..4d637ea6263799f9574ac23f0c8900949540dfec 100644
|
||||
index a7d255df89a42876d50f6e0648f7a397a9740141..d31c25f9d212efbb8a2107783206dd5c57eeb8cc 100644
|
||||
--- a/browser/app/profile/firefox.js
|
||||
+++ b/browser/app/profile/firefox.js
|
||||
@@ -2837,3 +2837,5 @@ pref("cookiebanners.ui.desktop.cfrVariant", 0);
|
||||
#ifdef MOZ_ARTIFACT_BUILDS
|
||||
pref("telemetry.fog.artifact_build", true);
|
||||
@@ -2836,3 +2836,5 @@ pref("cookiebanners.ui.desktop.cfrVariant", 0);
|
||||
#ifdef NIGHTLY_BUILD
|
||||
pref("dom.security.credentialmanagement.identity.enabled", true);
|
||||
#endif
|
||||
+
|
||||
+#include pulse-browser.js
|
||||
|
@ -1,5 +1,5 @@
|
||||
diff --git a/browser/base/content/browser-box.inc.xhtml b/browser/base/content/browser-box.inc.xhtml
|
||||
index ae5b1979921a9390ee899d72b04bc4ff293b39d8..7a18f16b76a5a7fa9566e1f02fbae9d80e1212b5 100644
|
||||
index d445abe7e743b2ec5d46d42f8f149c000e3c7997..552bc997c4ca1955fdd09232a360d9f9e91ce682 100644
|
||||
--- a/browser/base/content/browser-box.inc.xhtml
|
||||
+++ b/browser/base/content/browser-box.inc.xhtml
|
||||
@@ -3,9 +3,13 @@
|
||||
@ -12,8 +12,8 @@ index ae5b1979921a9390ee899d72b04bc4ff293b39d8..7a18f16b76a5a7fa9566e1f02fbae9d8
|
||||
+ </div>
|
||||
<vbox id="sidebar-box" hidden="true" class="chromeclass-extrachrome">
|
||||
<box id="sidebar-header" align="center">
|
||||
- <toolbarbutton id="sidebar-switcher-target" class="tabbable">
|
||||
+ <toolbarbutton id="sidebar-switcher-target" flex="1" class="tabbable">
|
||||
- <toolbarbutton id="sidebar-switcher-target" class="tabbable" aria-expanded="false">
|
||||
+ <toolbarbutton id="sidebar-switcher-target" class="tabbable" aria-expanded="false" flex="1">
|
||||
<image id="sidebar-icon" consumeanchor="sidebar-switcher-target"/>
|
||||
<label id="sidebar-title" crop="end" control="sidebar"/>
|
||||
<image id="sidebar-switcher-arrow"/>
|
||||
|
@ -1,5 +1,5 @@
|
||||
diff --git a/browser/base/content/browser-sidebar.js b/browser/base/content/browser-sidebar.js
|
||||
index d2b36db203f6572c39cc9a68cc71e4f7e2af0f07..738502d7c0dd9336a48270249818861dcdff9c1a 100644
|
||||
index f5def93f56fc8d02d6ae6834ca8d2df0aead2379..f984c600d27dabe102b0598135acd7e2f8f0d4e8 100644
|
||||
--- a/browser/base/content/browser-sidebar.js
|
||||
+++ b/browser/base/content/browser-sidebar.js
|
||||
@@ -11,6 +11,9 @@ var SidebarUI = {
|
||||
@ -74,17 +74,17 @@ index d2b36db203f6572c39cc9a68cc71e4f7e2af0f07..738502d7c0dd9336a48270249818861d
|
||||
]));
|
||||
},
|
||||
|
||||
@@ -62,6 +97,10 @@ var SidebarUI = {
|
||||
},
|
||||
@@ -63,6 +98,10 @@ var SidebarUI = {
|
||||
POSITION_START_PREF: "sidebar.position_start",
|
||||
DEFAULT_SIDEBAR_ID: "viewBookmarksSidebar",
|
||||
+
|
||||
|
||||
+ SIDEBAR_KEEP_TABS_ACTIVE_PREF: "pulse.sidebar.keeptabsactive.enabled",
|
||||
+ SIDEBAR_TABS_PREF: "pulse.sidebar.enabled",
|
||||
+ SIDEBAR_EXTENSIONS_PREF: "pulse.sidebar.extensions.enabled",
|
||||
|
||||
+
|
||||
// lastOpenedId is set in show() but unlike currentID it's not cleared out on hide
|
||||
// and isn't persisted across windows
|
||||
lastOpenedId: null,
|
||||
@@ -83,6 +122,15 @@ var SidebarUI = {
|
||||
_switcherArrow: null,
|
||||
_inited: false,
|
||||
@ -101,10 +101,11 @@ index d2b36db203f6572c39cc9a68cc71e4f7e2af0f07..738502d7c0dd9336a48270249818861d
|
||||
/**
|
||||
* @type {MutationObserver | null}
|
||||
*/
|
||||
@@ -112,20 +160,79 @@ var SidebarUI = {
|
||||
@@ -111,6 +159,48 @@ var SidebarUI = {
|
||||
this._switcherTarget.addEventListener("command", () => {
|
||||
this.toggleSwitcherPanel();
|
||||
});
|
||||
|
||||
+
|
||||
+ this._sidebarIcons = document.getElementById("sidebar-icons");
|
||||
+ this._sidebarIconsBottom = document.getElementById("sidebar-icons-bottom");
|
||||
+ this._sidebarTabs = document.getElementById("sidebar-container");
|
||||
@ -146,8 +147,10 @@ index d2b36db203f6572c39cc9a68cc71e4f7e2af0f07..738502d7c0dd9336a48270249818861d
|
||||
+
|
||||
+ this.loadedSidebars = [];
|
||||
+
|
||||
this._inited = true;
|
||||
|
||||
this._switcherTarget.addEventListener("keydown", event => {
|
||||
this.handleKeydown(event);
|
||||
});
|
||||
@@ -120,15 +210,33 @@ var SidebarUI = {
|
||||
Services.obs.addObserver(this, "intl:app-locales-changed");
|
||||
|
||||
this._initDeferred.resolve();
|
||||
@ -182,7 +185,7 @@ index d2b36db203f6572c39cc9a68cc71e4f7e2af0f07..738502d7c0dd9336a48270249818861d
|
||||
|
||||
if (this._box.hasAttribute("positionend")) {
|
||||
xulStore.persist(this._box, "positionend");
|
||||
@@ -157,7 +264,7 @@ var SidebarUI = {
|
||||
@@ -160,7 +268,7 @@ var SidebarUI = {
|
||||
/**
|
||||
* The handler for Services.obs.addObserver.
|
||||
**/
|
||||
@ -191,12 +194,12 @@ index d2b36db203f6572c39cc9a68cc71e4f7e2af0f07..738502d7c0dd9336a48270249818861d
|
||||
switch (topic) {
|
||||
case "intl:app-locales-changed": {
|
||||
if (this.isOpen) {
|
||||
@@ -168,6 +275,54 @@ var SidebarUI = {
|
||||
@@ -171,7 +279,55 @@ var SidebarUI = {
|
||||
this.showInitially(this.lastOpenedId);
|
||||
break;
|
||||
}
|
||||
+ break;
|
||||
+ }
|
||||
}
|
||||
+
|
||||
+ case "nsPref:changed": {
|
||||
+ switch (data) {
|
||||
@ -243,10 +246,11 @@ index d2b36db203f6572c39cc9a68cc71e4f7e2af0f07..738502d7c0dd9336a48270249818861d
|
||||
+ break;
|
||||
+ }
|
||||
+ break;
|
||||
}
|
||||
+ }
|
||||
}
|
||||
},
|
||||
@@ -284,17 +439,32 @@ var SidebarUI = {
|
||||
|
||||
@@ -290,17 +446,31 @@ var SidebarUI = {
|
||||
// First reset all ordinals to match DOM ordering.
|
||||
let browser = document.getElementById("browser");
|
||||
[...browser.children].forEach((node, i) => {
|
||||
@ -254,7 +258,6 @@ index d2b36db203f6572c39cc9a68cc71e4f7e2af0f07..738502d7c0dd9336a48270249818861d
|
||||
+ if (node.id == "TabsToolbar" || node.id == "verticaltabs-splitter") {
|
||||
+ return;
|
||||
+ }
|
||||
+
|
||||
node.style.order = i + 1;
|
||||
});
|
||||
|
||||
@ -284,7 +287,7 @@ index d2b36db203f6572c39cc9a68cc71e4f7e2af0f07..738502d7c0dd9336a48270249818861d
|
||||
// Indicate we've switched ordering to the box
|
||||
this._box.setAttribute("positionend", true);
|
||||
} else {
|
||||
@@ -483,6 +653,10 @@ var SidebarUI = {
|
||||
@@ -489,6 +659,10 @@ var SidebarUI = {
|
||||
},
|
||||
|
||||
_loadSidebarExtension(commandID) {
|
||||
@ -295,7 +298,7 @@ index d2b36db203f6572c39cc9a68cc71e4f7e2af0f07..738502d7c0dd9336a48270249818861d
|
||||
let sidebar = this.sidebars.get(commandID);
|
||||
let { extensionId } = sidebar;
|
||||
if (extensionId) {
|
||||
@@ -521,6 +695,7 @@ var SidebarUI = {
|
||||
@@ -527,6 +701,7 @@ var SidebarUI = {
|
||||
}
|
||||
|
||||
this._fireFocusedEvent();
|
||||
@ -303,7 +306,7 @@ index d2b36db203f6572c39cc9a68cc71e4f7e2af0f07..738502d7c0dd9336a48270249818861d
|
||||
return true;
|
||||
});
|
||||
},
|
||||
@@ -544,6 +719,7 @@ var SidebarUI = {
|
||||
@@ -550,6 +725,7 @@ var SidebarUI = {
|
||||
}
|
||||
return this._show(commandID).then(() => {
|
||||
this._loadSidebarExtension(commandID);
|
||||
@ -311,7 +314,7 @@ index d2b36db203f6572c39cc9a68cc71e4f7e2af0f07..738502d7c0dd9336a48270249818861d
|
||||
return true;
|
||||
});
|
||||
},
|
||||
@@ -557,6 +733,38 @@ var SidebarUI = {
|
||||
@@ -563,6 +739,38 @@ var SidebarUI = {
|
||||
*/
|
||||
_show(commandID) {
|
||||
return new Promise(resolve => {
|
||||
@ -350,7 +353,7 @@ index d2b36db203f6572c39cc9a68cc71e4f7e2af0f07..738502d7c0dd9336a48270249818861d
|
||||
this.selectMenuItem(commandID);
|
||||
|
||||
this._box.hidden = this._splitter.hidden = false;
|
||||
@@ -574,7 +782,13 @@ var SidebarUI = {
|
||||
@@ -580,7 +788,13 @@ var SidebarUI = {
|
||||
this.observeTitleChanges(sourceL10nEl);
|
||||
this.browser.setAttribute("src", url); // kick off async load
|
||||
|
||||
@ -365,25 +368,24 @@ index d2b36db203f6572c39cc9a68cc71e4f7e2af0f07..738502d7c0dd9336a48270249818861d
|
||||
this.browser.addEventListener(
|
||||
"load",
|
||||
event => {
|
||||
@@ -618,11 +832,14 @@ var SidebarUI = {
|
||||
@@ -624,11 +838,14 @@ var SidebarUI = {
|
||||
// create a new content viewer because the old one doesn't get destroyed
|
||||
// until about:blank has loaded (which does not happen as long as the
|
||||
// element is hidden).
|
||||
- this.browser.setAttribute("src", "about:blank");
|
||||
- this.browser.docShell.createAboutBlankContentViewer(null, null);
|
||||
-
|
||||
+ if (!this._keepTabsActivePref) {
|
||||
+ this.browser.setAttribute("src", "about:blank");
|
||||
+ this.browser.docShell.createAboutBlankContentViewer(null, null);
|
||||
+ }
|
||||
+
|
||||
|
||||
this._box.removeAttribute("checked");
|
||||
this._box.hidden = this._splitter.hidden = true;
|
||||
+ this._sidebarIcons.removeAttribute("checked");
|
||||
|
||||
let selBrowser = gBrowser.selectedBrowser;
|
||||
selBrowser.focus();
|
||||
@@ -636,10 +853,28 @@ var SidebarUI = {
|
||||
@@ -642,10 +859,28 @@ var SidebarUI = {
|
||||
* none if the argument is an empty string.
|
||||
*/
|
||||
selectMenuItem(commandID) {
|
||||
@ -413,7 +415,7 @@ index d2b36db203f6572c39cc9a68cc71e4f7e2af0f07..738502d7c0dd9336a48270249818861d
|
||||
if (id == commandID) {
|
||||
menu.setAttribute("checked", "true");
|
||||
if (triggerbutton) {
|
||||
@@ -655,6 +890,107 @@ var SidebarUI = {
|
||||
@@ -661,6 +896,107 @@ var SidebarUI = {
|
||||
}
|
||||
}
|
||||
},
|
||||
|
@ -1,16 +1,16 @@
|
||||
diff --git a/browser/components/customizableui/CustomizableUI.sys.mjs b/browser/components/customizableui/CustomizableUI.sys.mjs
|
||||
index ca629263080e3e2ba1d0ef2b15b11769fed433a8..ff5a28d40fdf2222ea7232c2a41182b4e305f92a 100644
|
||||
index e7ce84c0d6b0158aabfc2eb567de15281bafe4bc..3187056d1446530c8e7375b52d88026e459213cf 100644
|
||||
--- a/browser/components/customizableui/CustomizableUI.sys.mjs
|
||||
+++ b/browser/components/customizableui/CustomizableUI.sys.mjs
|
||||
@@ -12,6 +12,7 @@ ChromeUtils.defineESModuleGetters(lazy, {
|
||||
AddonManager: "resource://gre/modules/AddonManager.sys.mjs",
|
||||
@@ -13,6 +13,7 @@ ChromeUtils.defineESModuleGetters(lazy, {
|
||||
AddonManagerPrivate: "resource://gre/modules/AddonManager.sys.mjs",
|
||||
BrowserUsageTelemetry: "resource:///modules/BrowserUsageTelemetry.sys.mjs",
|
||||
CustomizableWidgets: "resource:///modules/CustomizableWidgets.sys.mjs",
|
||||
+ ExtensionCommon: "resource://gre/modules/ExtensionCommon.sys.mjs",
|
||||
HomePage: "resource:///modules/HomePage.sys.mjs",
|
||||
PanelMultiView: "resource:///modules/PanelMultiView.sys.mjs",
|
||||
PrivateBrowsingUtils: "resource://gre/modules/PrivateBrowsingUtils.sys.mjs",
|
||||
ShortcutUtils: "resource://gre/modules/ShortcutUtils.sys.mjs",
|
||||
@@ -29,6 +30,7 @@ XPCOMUtils.defineLazyGetter(lazy, "gWidgetsBundle", function () {
|
||||
@@ -26,6 +27,7 @@ XPCOMUtils.defineLazyGetter(lazy, "gWidgetsBundle", function () {
|
||||
});
|
||||
|
||||
const kDefaultThemeID = "default-theme@mozilla.org";
|
||||
@ -18,7 +18,7 @@ index ca629263080e3e2ba1d0ef2b15b11769fed433a8..ff5a28d40fdf2222ea7232c2a41182b4
|
||||
|
||||
const kSpecialWidgetPfx = "customizableui-special-";
|
||||
|
||||
@@ -238,17 +240,18 @@ var CustomizableUIInternal = {
|
||||
@@ -235,17 +237,18 @@ var CustomizableUIInternal = {
|
||||
false
|
||||
);
|
||||
|
||||
|
@ -1,34 +1,18 @@
|
||||
diff --git a/browser/components/extensions/parent/ext-sidebarAction.js b/browser/components/extensions/parent/ext-sidebarAction.js
|
||||
index 6adb116e4a3b7113f4b133a36bb575dfdcf2ca2e..d5d8956a4de92e28584941ea00be98ae0d020035 100644
|
||||
index a798801ebfaabaf96bf194fc2f2c6c31f852f149..9231c3b1cf92da5bc7feec1e73aa2b80c35c819e 100644
|
||||
--- a/browser/components/extensions/parent/ext-sidebarAction.js
|
||||
+++ b/browser/components/extensions/parent/ext-sidebarAction.js
|
||||
@@ -14,6 +14,7 @@ var { ExtensionError } = ExtensionUtils;
|
||||
|
||||
var { IconDetails } = ExtensionParent;
|
||||
|
||||
+
|
||||
// WeakMap[Extension -> SidebarAction]
|
||||
let sidebarActionMap = new WeakMap();
|
||||
|
||||
@@ -95,6 +96,7 @@ this.sidebarAction = class extends ExtensionAPI {
|
||||
|
||||
this.tabContext.shutdown();
|
||||
|
||||
+
|
||||
// Don't remove everything on app shutdown so session restore can handle
|
||||
// restoring open sidebars.
|
||||
if (isAppShutdown) {
|
||||
@@ -116,6 +118,9 @@ this.sidebarAction = class extends ExtensionAPI {
|
||||
}
|
||||
@@ -109,7 +109,8 @@ this.sidebarAction = class extends ExtensionAPI {
|
||||
document.getElementById(this.menuId)?.remove();
|
||||
document.getElementById(this.switcherMenuId)?.remove();
|
||||
let header = document.getElementById("sidebar-switcher-target");
|
||||
header.removeEventListener("SidebarShown", this.updateHeader);
|
||||
+
|
||||
- header.removeEventListener("SidebarShown", this.updateHeader);
|
||||
+ // Delete sidebar item
|
||||
+ SidebarUI.deleteSidebarItem(this.id);
|
||||
+ SidebarUI.deleteSidebarItem(this.id); header.removeEventListener("SidebarShown", this.updateHeader);
|
||||
SidebarUI.sidebars.delete(this.id);
|
||||
}
|
||||
windowTracker.removeOpenListener(this.windowOpenListener);
|
||||
@@ -129,6 +134,8 @@ this.sidebarAction = class extends ExtensionAPI {
|
||||
@@ -123,6 +124,8 @@ this.sidebarAction = class extends ExtensionAPI {
|
||||
if (SidebarUI.lastOpenedId === sidebarId) {
|
||||
SidebarUI.lastOpenedId = null;
|
||||
}
|
||||
@ -37,7 +21,7 @@ index 6adb116e4a3b7113f4b133a36bb575dfdcf2ca2e..d5d8956a4de92e28584941ea00be98ae
|
||||
}
|
||||
}
|
||||
|
||||
@@ -157,21 +164,30 @@ this.sidebarAction = class extends ExtensionAPI {
|
||||
@@ -151,11 +154,16 @@ this.sidebarAction = class extends ExtensionAPI {
|
||||
}
|
||||
let { document, SidebarUI } = window;
|
||||
let keyId = `ext-key-id-${this.id}`;
|
||||
@ -51,20 +35,15 @@ index 6adb116e4a3b7113f4b133a36bb575dfdcf2ca2e..d5d8956a4de92e28584941ea00be98ae
|
||||
url: sidebarURL,
|
||||
menuId: this.menuId,
|
||||
+ iconurl: getIcon(16),
|
||||
buttonId: this.buttonId,
|
||||
switcherMenuId: this.switcherMenuId,
|
||||
// The following properties are specific to extensions
|
||||
extensionId: this.extension.id,
|
||||
panel: details.panel,
|
||||
@@ -163,6 +171,8 @@ this.sidebarAction = class extends ExtensionAPI {
|
||||
browserStyle: this.browserStyle,
|
||||
});
|
||||
+
|
||||
+ SidebarUI.createSidebarItem(this.id, SidebarUI.sidebars.get(this.id));
|
||||
|
||||
+ SidebarUI.createSidebarItem(this.id, SidebarUI.sidebars.get(this.id));
|
||||
+
|
||||
let header = document.getElementById("sidebar-switcher-target");
|
||||
header.addEventListener("SidebarShown", this.updateHeader);
|
||||
|
||||
+
|
||||
+
|
||||
// Insert a menuitem for View->Show Sidebars.
|
||||
let menuitem = document.createXULElement("menuitem");
|
||||
menuitem.setAttribute("id", this.menuId);
|
||||
|
@ -1,5 +1,5 @@
|
||||
diff --git a/browser/components/moz.build b/browser/components/moz.build
|
||||
index 3b2126e66efa27d4b941ceb93b46a04aa3cdef30..bbc1b8b248f32bf17764813402abf224b4bc38c1 100644
|
||||
index 94b328a9b049e0ae4cfafe2887c2b31d6d0dfefa..f60cab84bf16fdc3e6295ee0ad5e14a09b756355 100644
|
||||
--- a/browser/components/moz.build
|
||||
+++ b/browser/components/moz.build
|
||||
@@ -63,6 +63,9 @@ DIRS += [
|
||||
@ -11,4 +11,4 @@ index 3b2126e66efa27d4b941ceb93b46a04aa3cdef30..bbc1b8b248f32bf17764813402abf224
|
||||
+
|
||||
DIRS += ["build"]
|
||||
|
||||
|
||||
if CONFIG["NIGHTLY_BUILD"]:
|
||||
|
@ -1,19 +0,0 @@
|
||||
diff --git a/browser/components/preferences/preferences.js b/browser/components/preferences/preferences.js
|
||||
index d3a1fce03d4f2109532f32cbaa027600505de5a6..6c14b0079f5677bf8f4b465473d4909da65d33bb 100644
|
||||
--- a/browser/components/preferences/preferences.js
|
||||
+++ b/browser/components/preferences/preferences.js
|
||||
@@ -156,7 +156,13 @@ function register_module(categoryName, categoryObject) {
|
||||
if (template) {
|
||||
// Replace the template element with the nodes inside of it.
|
||||
let frag = template.content;
|
||||
- await document.l10n.translateFragment(frag);
|
||||
+
|
||||
+ // Pulse Browser
|
||||
+ // Something seems to be bugged out here, but it doesn't matter. So, the
|
||||
+ // simple solution is to silent catch the error...
|
||||
+ try {
|
||||
+ await document.l10n.translateFragment(frag);
|
||||
+ } catch (e) {}
|
||||
|
||||
// Actually insert them into the DOM.
|
||||
document.l10n.pauseObserving();
|
Loading…
Reference in New Issue
Block a user