mirror of
https://github.com/zen-browser/desktop.git
synced 2026-07-15 13:20:30 +00:00
Merge branch 'dev' into library
Signed-off-by: mr. m <91018726+mr-cheffy@users.noreply.github.com>
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
diff --git a/browser/components/BrowserContentHandler.sys.mjs b/browser/components/BrowserContentHandler.sys.mjs
|
||||
index 430c6877c81824d8ab318cacc997d4eda4cb6a11..e8a195e1fe09952b90a0d73d13c6c15da2006bd4 100644
|
||||
index 4bfb4199dafac004486dfc61db954173742a010a..542c156432b9d7c2190c0d14ce9cfd09814422bf 100644
|
||||
--- a/browser/components/BrowserContentHandler.sys.mjs
|
||||
+++ b/browser/components/BrowserContentHandler.sys.mjs
|
||||
@@ -603,6 +603,28 @@ nsBrowserContentHandler.prototype = {
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
diff --git a/browser/components/BrowserGlue.sys.mjs b/browser/components/BrowserGlue.sys.mjs
|
||||
index af635211046f9f1b2d473a14e8170837cd0d93cd..f07514a7e3ab55aa3321f0a7c0c092e91c2961ce 100644
|
||||
index d07aaa3fbb8ccb02ae00d845649dc9c1d623cba5..68d3a4800f14fef5b5e7df9cd9afe3bc85358bed 100644
|
||||
--- a/browser/components/BrowserGlue.sys.mjs
|
||||
+++ b/browser/components/BrowserGlue.sys.mjs
|
||||
@@ -8,6 +8,7 @@ import { XPCOMUtils } from "resource://gre/modules/XPCOMUtils.sys.mjs";
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
diff --git a/browser/components/aboutlogins/content/aboutLogins.html b/browser/components/aboutlogins/content/aboutLogins.html
|
||||
index ca69defe40c57704ab6ec331ce11c95a98b03e8f..bc5be4555adbe3389bceee0f01730ee57f1e69ef 100644
|
||||
index 9bbf5e69b17139d5063977334a869db090af3de1..9778bf2843afbb60b470ee637534946e6f7917a8 100644
|
||||
--- a/browser/components/aboutlogins/content/aboutLogins.html
|
||||
+++ b/browser/components/aboutlogins/content/aboutLogins.html
|
||||
@@ -6,7 +6,7 @@
|
||||
|
||||
@@ -1,20 +1,20 @@
|
||||
diff --git a/browser/components/aboutwelcome/content/aboutwelcome.css b/browser/components/aboutwelcome/content/aboutwelcome.css
|
||||
index 98497769b135efd3200607ee2cf50e82d06ed3fd..68e0778cfc4dc70935a3d48e79542b4133b293d2 100644
|
||||
index 4a568479995c43ec2801c5b2f9452610923233ed..857a4a0ed78f3d374ed45fc4ff73e8e51dfbc2b9 100644
|
||||
--- a/browser/components/aboutwelcome/content/aboutwelcome.css
|
||||
+++ b/browser/components/aboutwelcome/content/aboutwelcome.css
|
||||
@@ -330,6 +330,11 @@ panel#feature-callout {
|
||||
--panel-shadow-margin: 6px;
|
||||
--panel-arrow-space: calc(var(--panel-shadow-margin) + var(--arrow-visible-height) - 1.5px);
|
||||
--panel-margin-offset: calc(-1 * (var(--panel-shadow-margin) + var(--arrow-corner-distance) + (var(--arrow-width) / 2)));
|
||||
--panel-box-shadow-margin: 6px;
|
||||
--panel-arrow-space: calc(var(--panel-box-shadow-margin) + var(--arrow-visible-height) - 1.5px);
|
||||
--panel-margin-offset: calc(-1 * (var(--panel-box-shadow-margin) + var(--arrow-corner-distance) + (var(--arrow-width) / 2)));
|
||||
+
|
||||
+ @media -moz-pref("widget.macos.native-popovers") and (-moz-platform: macos) {
|
||||
+ --panel-shadow-margin: 0;
|
||||
+ --panel-box-shadow-margin: 0;
|
||||
+ --panel-arrow-space: 0;
|
||||
+ }
|
||||
}
|
||||
|
||||
panel#feature-callout::part(content) {
|
||||
@@ -517,6 +522,12 @@ div#feature-callout.hidden {
|
||||
@@ -518,6 +523,12 @@ div#feature-callout.hidden {
|
||||
width: 25em;
|
||||
gap: 16px;
|
||||
background: var(--fc-background);
|
||||
@@ -27,7 +27,7 @@ index 98497769b135efd3200607ee2cf50e82d06ed3fd..68e0778cfc4dc70935a3d48e79542b41
|
||||
}
|
||||
#feature-callout .screen[pos=callout] .section-main .main-content .main-content-inner {
|
||||
gap: 12px;
|
||||
@@ -933,6 +944,10 @@ panel#feature-callout::part(content) {
|
||||
@@ -934,6 +945,10 @@ panel#feature-callout::part(content) {
|
||||
overflow: visible;
|
||||
transform: rotate(45deg);
|
||||
transform-style: preserve-3d;
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
diff --git a/browser/components/aiwindow/ui/modules/AIWindow.sys.mjs b/browser/components/aiwindow/ui/modules/AIWindow.sys.mjs
|
||||
index 97710ab0570a1a477ef4ed74a78c16448dfb7674..7d8ba5b1f2f330175fb57b906bb572fd7e1d36c8 100644
|
||||
index f6f1dd1f6b4d21d27e39b48bb7a57871ad5d019d..bf743120cf9f137cbe06d05896f706fb3d5b9435 100644
|
||||
--- a/browser/components/aiwindow/ui/modules/AIWindow.sys.mjs
|
||||
+++ b/browser/components/aiwindow/ui/modules/AIWindow.sys.mjs
|
||||
@@ -277,6 +277,7 @@ export const AIWindow = {
|
||||
@@ -287,6 +287,7 @@ export const AIWindow = {
|
||||
},
|
||||
|
||||
_updateToolbarButtonPositions(win, { isToggling = false } = {}) {
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
diff --git a/browser/components/asrouter/modules/FeatureCallout.sys.mjs b/browser/components/asrouter/modules/FeatureCallout.sys.mjs
|
||||
index f176498a3130b61ac5e75fce8208d1b9eaf13f81..d133526ab5bf3db53e459c36d5f9a7ff37ef972f 100644
|
||||
index c4638d2d557f05fa6638cd379be8e0076336f8dc..2e25f485aa94485d12ca9e98aa4eaf56a06cf1f8 100644
|
||||
--- a/browser/components/asrouter/modules/FeatureCallout.sys.mjs
|
||||
+++ b/browser/components/asrouter/modules/FeatureCallout.sys.mjs
|
||||
@@ -778,6 +778,7 @@ export class FeatureCallout {
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
diff --git a/browser/components/customizableui/CustomizableUI.sys.mjs b/browser/components/customizableui/CustomizableUI.sys.mjs
|
||||
index 5905271a3343efa04b45f5d1a63bfca3de342755..37f57de0ad72271d4c6e188ab9841b23b95f08d0 100644
|
||||
index d5d4596739cde5d3d49d6294867f5da122c526b8..c206cfb374542c496be9bf0305a0a80bbcf503b2 100644
|
||||
--- a/browser/components/customizableui/CustomizableUI.sys.mjs
|
||||
+++ b/browser/components/customizableui/CustomizableUI.sys.mjs
|
||||
@@ -13,6 +13,7 @@ ChromeUtils.defineESModuleGetters(lazy, {
|
||||
@@ -120,7 +120,7 @@ index 5905271a3343efa04b45f5d1a63bfca3de342755..37f57de0ad72271d4c6e188ab9841b23
|
||||
* The identifier string of the area that aNode is being inserted into.
|
||||
*/
|
||||
insertWidgetBefore(aNode, aNextNode, aContainer, aAreaId) {
|
||||
+ if (aAreaId === CustomizableUI.AREA_NAVBAR && aNode.ownerGlobal.gZenVerticalTabsManager._hasSetSingleToolbar) {
|
||||
+ if (aAreaId === CustomizableUI.AREA_NAVBAR && aNode.documentGlobal.gZenVerticalTabsManager._hasSetSingleToolbar) {
|
||||
+ aContainer = aNode.ownerDocument.getElementById("zen-sidebar-top-buttons-customization-target");
|
||||
+ aAreaId = "zen-sidebar-top-buttons";
|
||||
+ }
|
||||
@@ -139,7 +139,7 @@ index 5905271a3343efa04b45f5d1a63bfca3de342755..37f57de0ad72271d4c6e188ab9841b23
|
||||
@@ -4573,7 +4571,7 @@ var CustomizableUIInternal = {
|
||||
if (area.get("type") == CustomizableUI.TYPE_TOOLBAR) {
|
||||
let defaultCollapsed = area.get("defaultCollapsed");
|
||||
let win = areaNode.ownerGlobal;
|
||||
let win = areaNode.documentGlobal;
|
||||
- if (defaultCollapsed !== null) {
|
||||
+ if (defaultCollapsed !== null && !zenDontRebuildCollapsed) {
|
||||
win.setToolbarVisibility(
|
||||
@@ -186,7 +186,7 @@ index 5905271a3343efa04b45f5d1a63bfca3de342755..37f57de0ad72271d4c6e188ab9841b23
|
||||
});
|
||||
|
||||
lazy.log.debug(
|
||||
@@ -7930,7 +7931,37 @@ class OverflowableToolbar {
|
||||
@@ -7930,7 +7931,39 @@ class OverflowableToolbar {
|
||||
Math.max(targetWidth, targetChildrenWidth)
|
||||
);
|
||||
totalAvailWidth = Math.ceil(totalAvailWidth);
|
||||
@@ -194,6 +194,8 @@ index 5905271a3343efa04b45f5d1a63bfca3de342755..37f57de0ad72271d4c6e188ab9841b23
|
||||
+ if (this.#target.id == 'nav-bar-customization-target' &&
|
||||
+ win.gZenVerticalTabsManager._hasSetSingleToolbar &&
|
||||
+ Services.prefs.getBoolPref("zen.view.overflow-webext-toolbar", true) &&
|
||||
+ !win.document.documentElement.hasAttribute("zen-creating-workspace") &&
|
||||
+ !win.document.documentElement.hasAttribute("inDOMFullscreen") &&
|
||||
+ !win.gURLBar.hasAttribute("breakout-extend")) {
|
||||
+ const availSelectors = ":is(#page-action-buttons, #zen-copy-url-button, .unified-extensions-item, .urlbar-addon-page-action)";
|
||||
+ const width = [
|
||||
@@ -225,7 +227,7 @@ index 5905271a3343efa04b45f5d1a63bfca3de342755..37f57de0ad72271d4c6e188ab9841b23
|
||||
return { isOverflowing, targetContentWidth, totalAvailWidth };
|
||||
}
|
||||
|
||||
@@ -7991,7 +8022,11 @@ class OverflowableToolbar {
|
||||
@@ -7991,7 +8024,11 @@ class OverflowableToolbar {
|
||||
return;
|
||||
}
|
||||
}
|
||||
@@ -238,7 +240,7 @@ index 5905271a3343efa04b45f5d1a63bfca3de342755..37f57de0ad72271d4c6e188ab9841b23
|
||||
lazy.log.debug(
|
||||
`Need ${minSize} but width is ${totalAvailWidth} so bailing`
|
||||
);
|
||||
@@ -8024,7 +8059,7 @@ class OverflowableToolbar {
|
||||
@@ -8024,7 +8061,7 @@ class OverflowableToolbar {
|
||||
}
|
||||
}
|
||||
if (!inserted) {
|
||||
@@ -247,7 +249,7 @@ index 5905271a3343efa04b45f5d1a63bfca3de342755..37f57de0ad72271d4c6e188ab9841b23
|
||||
}
|
||||
child.removeAttribute("cui-anchorid");
|
||||
child.removeAttribute("overflowedItem");
|
||||
@@ -8150,6 +8185,9 @@ class OverflowableToolbar {
|
||||
@@ -8150,6 +8187,9 @@ class OverflowableToolbar {
|
||||
* if no such list exists.
|
||||
*/
|
||||
get #webExtList() {
|
||||
@@ -257,8 +259,8 @@ index 5905271a3343efa04b45f5d1a63bfca3de342755..37f57de0ad72271d4c6e188ab9841b23
|
||||
if (!this.#webExtListRef) {
|
||||
let targetID = this.#toolbar.getAttribute("addon-webext-overflowtarget");
|
||||
if (!targetID) {
|
||||
@@ -8161,6 +8199,9 @@ class OverflowableToolbar {
|
||||
let win = this.#toolbar.ownerGlobal;
|
||||
@@ -8161,6 +8201,9 @@ class OverflowableToolbar {
|
||||
let win = this.#toolbar.documentGlobal;
|
||||
let { panel } = win.gUnifiedExtensions;
|
||||
this.#webExtListRef = panel.querySelector(`#${targetID}`);
|
||||
+ if (!this.#webExtListRef) {
|
||||
@@ -267,7 +269,7 @@ index 5905271a3343efa04b45f5d1a63bfca3de342755..37f57de0ad72271d4c6e188ab9841b23
|
||||
}
|
||||
return this.#webExtListRef;
|
||||
}
|
||||
@@ -8369,7 +8410,7 @@ class OverflowableToolbar {
|
||||
@@ -8369,7 +8412,7 @@ class OverflowableToolbar {
|
||||
break;
|
||||
}
|
||||
case "mousedown": {
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
diff --git a/browser/components/customizableui/CustomizeMode.sys.mjs b/browser/components/customizableui/CustomizeMode.sys.mjs
|
||||
index e72ff7eab14f66ff4454850930a1d7266b3acefa..1a5d9c63b8942e8c20e9f91b82b5b11647b12ecc 100644
|
||||
index 25eb66b96a30c86e08376577f4636e159a02c76e..9b997ab559ddade67a7390539b3b4f9275c27a20 100644
|
||||
--- a/browser/components/customizableui/CustomizeMode.sys.mjs
|
||||
+++ b/browser/components/customizableui/CustomizeMode.sys.mjs
|
||||
@@ -503,7 +503,7 @@ export class CustomizeMode {
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
diff --git a/browser/components/customizableui/ToolbarContextMenu.sys.mjs b/browser/components/customizableui/ToolbarContextMenu.sys.mjs
|
||||
index d5fd707b98e4b163a624c97ff4a8f2574e0b0180..b5d7e84c3567e83b95a6493e8333d3036dc88f36 100644
|
||||
index c3803a5d759eefb728fc0ec86af282bb5e2d5cc1..e4bc4242e05d28603f324133f338273fd76ee0b3 100644
|
||||
--- a/browser/components/customizableui/ToolbarContextMenu.sys.mjs
|
||||
+++ b/browser/components/customizableui/ToolbarContextMenu.sys.mjs
|
||||
@@ -183,7 +183,7 @@ export var ToolbarContextMenu = {
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
diff --git a/browser/components/customizableui/content/panelUI.inc.xhtml b/browser/components/customizableui/content/panelUI.inc.xhtml
|
||||
index 6cb22be6526b17d952a90fd414c49a31e9afde7a..84f8156e88027a79a40f14c77c83d6a2d19c8a72 100644
|
||||
index 5c248c0d49f3d9378260230c24ab60a4157dc438..1e87a1d040ed82c7edfb31f9e5853a4fb299b503 100644
|
||||
--- a/browser/components/customizableui/content/panelUI.inc.xhtml
|
||||
+++ b/browser/components/customizableui/content/panelUI.inc.xhtml
|
||||
@@ -139,7 +139,7 @@
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
diff --git a/browser/components/customizableui/content/panelUI.js b/browser/components/customizableui/content/panelUI.js
|
||||
index 5a469ce153dada011144fb4b66747c41e778ff1e..83bedb74df5b4064e8a0580f8b2ee9c0c27f81a8 100644
|
||||
index 140ea6eddd0d0c6817bbaabf2dc00083eaa11b13..0fe33867cf64d02b2b6e6db8b6844a4ea044ad33 100644
|
||||
--- a/browser/components/customizableui/content/panelUI.js
|
||||
+++ b/browser/components/customizableui/content/panelUI.js
|
||||
@@ -666,10 +666,12 @@ const PanelUI = {
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
diff --git a/browser/components/extensions/parent/ext-browser.js b/browser/components/extensions/parent/ext-browser.js
|
||||
index d1209bc2c828a19ade8cc027cdea6f42007f0de6..0a2def2f3c32618304cd8a263906b0c6e040dcbc 100644
|
||||
index aca5a23deda6b0f2316b0e108cff20ffd7feda67..a06c90937f97a4994b0807b54984089dbe627a71 100644
|
||||
--- a/browser/components/extensions/parent/ext-browser.js
|
||||
+++ b/browser/components/extensions/parent/ext-browser.js
|
||||
@@ -352,6 +352,7 @@ class TabTracker extends TabTrackerBase {
|
||||
@@ -11,7 +11,7 @@ index d1209bc2c828a19ade8cc027cdea6f42007f0de6..0a2def2f3c32618304cd8a263906b0c6
|
||||
if (id) {
|
||||
return id;
|
||||
@@ -386,6 +387,7 @@ class TabTracker extends TabTrackerBase {
|
||||
if (nativeTab.ownerGlobal.closed) {
|
||||
if (nativeTab.documentGlobal.closed) {
|
||||
throw new Error("Cannot attach ID to a tab in a closed window.");
|
||||
}
|
||||
+ if (nativeTab.hasAttribute("zen-empty-tab")) return;
|
||||
@@ -27,5 +27,5 @@ index d1209bc2c828a19ade8cc027cdea6f42007f0de6..0a2def2f3c32618304cd8a263906b0c6
|
||||
+ }
|
||||
+
|
||||
// Check private browsing access at browser window level.
|
||||
if (!this.extension.canAccessWindow(nativeTab.ownerGlobal)) {
|
||||
if (!this.extension.canAccessWindow(nativeTab.documentGlobal)) {
|
||||
return false;
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
diff --git a/browser/components/extensions/parent/ext-tabs.js b/browser/components/extensions/parent/ext-tabs.js
|
||||
index 636e0f8cd1d489658833cf101152576e9fdb52af..e7578a059504b89a852061be037c323a107fe5ce 100644
|
||||
index 8f5fdecc9394d42a1460a1b73fb8c4e92f63c41e..82c03e234289c7b00f49f73854be45fb95fb91d7 100644
|
||||
--- a/browser/components/extensions/parent/ext-tabs.js
|
||||
+++ b/browser/components/extensions/parent/ext-tabs.js
|
||||
@@ -514,6 +514,7 @@ this.tabs = class extends ExtensionAPIPersistent {
|
||||
|
||||
13
src/browser/components/nova/NovaPrefs-sys-mjs.patch
Normal file
13
src/browser/components/nova/NovaPrefs-sys-mjs.patch
Normal file
@@ -0,0 +1,13 @@
|
||||
diff --git a/browser/components/nova/NovaPrefs.sys.mjs b/browser/components/nova/NovaPrefs.sys.mjs
|
||||
index 3d22c881c481643fcffbc581523905a1847a7d41..453dd4d9c43d7483c037a993afbf2b854533497c 100644
|
||||
--- a/browser/components/nova/NovaPrefs.sys.mjs
|
||||
+++ b/browser/components/nova/NovaPrefs.sys.mjs
|
||||
@@ -18,7 +18,7 @@ const PLATFORM_PREFS = (() => {
|
||||
})();
|
||||
|
||||
function applyNovaPlatformDefaults() {
|
||||
- const on = Services.prefs.getBoolPref("browser.nova.enabled", false);
|
||||
+ const on = true;
|
||||
const defaults = Services.prefs.getDefaultBranch("");
|
||||
for (const pref of PLATFORM_PREFS) {
|
||||
defaults.setBoolPref(pref, on);
|
||||
@@ -1,5 +1,5 @@
|
||||
diff --git a/browser/components/places/PlacesUIUtils.sys.mjs b/browser/components/places/PlacesUIUtils.sys.mjs
|
||||
index b21f7721dea2d485ccba1fd6fd7e65e17480e3d3..89048d9ea2b4edf2b0cab77f661c07f4d9453c3f 100644
|
||||
index 7c2786cc1be512ddfc165fb8f6514131ac033040..5846aff53030ef0fad2f87d017ba3713889b474d 100644
|
||||
--- a/browser/components/places/PlacesUIUtils.sys.mjs
|
||||
+++ b/browser/components/places/PlacesUIUtils.sys.mjs
|
||||
@@ -61,6 +61,7 @@ class BookmarkState {
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
diff --git a/browser/components/places/content/browserPlacesViews.js b/browser/components/places/content/browserPlacesViews.js
|
||||
index 463913926c58e6c622e0fcc60534921f02814829..0143c48c48e132464226db810f4ea4d2720c3c49 100644
|
||||
index 229e7960fc461475426b538f3a5fdc134a99ebcf..22b0eb8e23fc56cd4d8892e3ecebe389ea00ce1f 100644
|
||||
--- a/browser/components/places/content/browserPlacesViews.js
|
||||
+++ b/browser/components/places/content/browserPlacesViews.js
|
||||
@@ -328,12 +328,23 @@ class PlacesViewBase {
|
||||
@@ -343,12 +343,23 @@ class PlacesViewBase {
|
||||
|
||||
this._cleanPopup(aPopup);
|
||||
|
||||
@@ -29,7 +29,7 @@ index 463913926c58e6c622e0fcc60534921f02814829..0143c48c48e132464226db810f4ea4d2
|
||||
this._insertNewItemToPopup(child, fragment);
|
||||
}
|
||||
aPopup.insertBefore(fragment, aPopup._endMarker);
|
||||
@@ -391,6 +402,7 @@ class PlacesViewBase {
|
||||
@@ -406,6 +417,7 @@ class PlacesViewBase {
|
||||
"scheme",
|
||||
PlacesUIUtils.guessUrlSchemeForUI(aPlacesNode.uri)
|
||||
);
|
||||
@@ -37,7 +37,7 @@ index 463913926c58e6c622e0fcc60534921f02814829..0143c48c48e132464226db810f4ea4d2
|
||||
} else if (PlacesUtils.containerTypes.includes(type)) {
|
||||
element = document.createXULElement("menu");
|
||||
element.setAttribute("container", "true");
|
||||
@@ -1058,25 +1070,33 @@ class PlacesToolbar extends PlacesViewBase {
|
||||
@@ -1076,25 +1088,33 @@ class PlacesToolbar extends PlacesViewBase {
|
||||
this._rootElt.firstChild.remove();
|
||||
}
|
||||
|
||||
@@ -82,7 +82,7 @@ index 463913926c58e6c622e0fcc60534921f02814829..0143c48c48e132464226db810f4ea4d2
|
||||
);
|
||||
++startIndex;
|
||||
if (elt.localName != "toolbarseparator") {
|
||||
@@ -1084,15 +1104,12 @@ class PlacesToolbar extends PlacesViewBase {
|
||||
@@ -1102,15 +1122,12 @@ class PlacesToolbar extends PlacesViewBase {
|
||||
}
|
||||
}
|
||||
if (!elt) {
|
||||
@@ -101,7 +101,7 @@ index 463913926c58e6c622e0fcc60534921f02814829..0143c48c48e132464226db810f4ea4d2
|
||||
});
|
||||
});
|
||||
|
||||
@@ -1102,7 +1119,7 @@ class PlacesToolbar extends PlacesViewBase {
|
||||
@@ -1120,7 +1137,7 @@ class PlacesToolbar extends PlacesViewBase {
|
||||
|
||||
let fragment = document.createDocumentFragment();
|
||||
for (let i = startIndex; i < limit; ++i) {
|
||||
@@ -110,7 +110,7 @@ index 463913926c58e6c622e0fcc60534921f02814829..0143c48c48e132464226db810f4ea4d2
|
||||
}
|
||||
await new Promise(resolve => window.requestAnimationFrame(resolve));
|
||||
if (!this._isAlive) {
|
||||
@@ -1165,6 +1182,8 @@ class PlacesToolbar extends PlacesViewBase {
|
||||
@@ -1183,6 +1200,8 @@ class PlacesToolbar extends PlacesViewBase {
|
||||
"scheme",
|
||||
PlacesUIUtils.guessUrlSchemeForUI(aChild.uri)
|
||||
);
|
||||
@@ -119,7 +119,7 @@ index 463913926c58e6c622e0fcc60534921f02814829..0143c48c48e132464226db810f4ea4d2
|
||||
}
|
||||
}
|
||||
|
||||
@@ -2359,7 +2378,7 @@ this.PlacesPanelview = class PlacesPanelview extends PlacesViewBase {
|
||||
@@ -2395,7 +2414,7 @@ this.PlacesPanelview = class PlacesPanelview extends PlacesViewBase {
|
||||
PlacesUIUtils.guessUrlSchemeForUI(placesNode.uri)
|
||||
);
|
||||
element.setAttribute("label", PlacesUIUtils.getBestTitle(placesNode));
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
diff --git a/browser/components/places/content/editBookmark.js b/browser/components/places/content/editBookmark.js
|
||||
index 0fb2225d0fadd27e9e7851be77f18afe7d053c80..347203d6ea9cab3cb803f28515613229b6a454b3 100644
|
||||
index f5df770e7c03446c2d23664b9100e12149ea7a59..398ae5b75a27aec60341f3058310013dcf6138d6 100644
|
||||
--- a/browser/components/places/content/editBookmark.js
|
||||
+++ b/browser/components/places/content/editBookmark.js
|
||||
@@ -387,6 +387,10 @@ var gEditItemOverlay = {
|
||||
@@ -389,6 +389,10 @@ var gEditItemOverlay = {
|
||||
this._keywordField.readOnly = this.readOnly;
|
||||
}
|
||||
|
||||
@@ -13,7 +13,7 @@ index 0fb2225d0fadd27e9e7851be77f18afe7d053c80..347203d6ea9cab3cb803f28515613229
|
||||
// Collapse the tag selector if the item does not accept tags.
|
||||
if (showOrCollapse("tagsRow", isBookmark || bulkTagging, "tags")) {
|
||||
this._initTagsField();
|
||||
@@ -693,6 +697,7 @@ var gEditItemOverlay = {
|
||||
@@ -702,6 +706,7 @@ var gEditItemOverlay = {
|
||||
if (this._paneInfo.isBookmark) {
|
||||
options.tags = this._element("tagsField").value;
|
||||
options.keyword = this._keyword;
|
||||
@@ -21,7 +21,7 @@ index 0fb2225d0fadd27e9e7851be77f18afe7d053c80..347203d6ea9cab3cb803f28515613229
|
||||
}
|
||||
|
||||
if (this._paneInfo.bulkTagging) {
|
||||
@@ -1178,6 +1183,9 @@ var gEditItemOverlay = {
|
||||
@@ -1190,6 +1195,9 @@ var gEditItemOverlay = {
|
||||
case "editBMPanel_tagsSelectorExpander":
|
||||
this.toggleTagsSelector().catch(console.error);
|
||||
break;
|
||||
@@ -31,7 +31,7 @@ index 0fb2225d0fadd27e9e7851be77f18afe7d053c80..347203d6ea9cab3cb803f28515613229
|
||||
}
|
||||
break;
|
||||
}
|
||||
@@ -1256,6 +1264,128 @@ var gEditItemOverlay = {
|
||||
@@ -1268,6 +1276,128 @@ var gEditItemOverlay = {
|
||||
get bookmarkState() {
|
||||
return this._bookmarkState;
|
||||
},
|
||||
@@ -160,7 +160,7 @@ index 0fb2225d0fadd27e9e7851be77f18afe7d053c80..347203d6ea9cab3cb803f28515613229
|
||||
};
|
||||
|
||||
ChromeUtils.defineLazyGetter(gEditItemOverlay, "_folderTree", () => {
|
||||
@@ -1294,6 +1424,9 @@ for (let elt of [
|
||||
@@ -1306,6 +1436,9 @@ for (let elt of [
|
||||
"locationField",
|
||||
"keywordField",
|
||||
"tagsField",
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
diff --git a/browser/components/places/content/editBookmarkPanel.inc.xhtml b/browser/components/places/content/editBookmarkPanel.inc.xhtml
|
||||
index 40366677b60123c66bf0739d1b2374b423d3061c..a2774e99726407d95011126ea2a272f08eaf0961 100644
|
||||
index eb23018327ff6eef7c28683d695bcf610fcc87d2..6627c4b5594d440527208236f784365b06a79411 100644
|
||||
--- a/browser/components/places/content/editBookmarkPanel.inc.xhtml
|
||||
+++ b/browser/components/places/content/editBookmarkPanel.inc.xhtml
|
||||
@@ -12,14 +12,15 @@
|
||||
@@ -20,7 +20,7 @@ index 40366677b60123c66bf0739d1b2374b423d3061c..a2774e99726407d95011126ea2a272f0
|
||||
<label data-l10n-id="bookmark-overlay-location-2"
|
||||
class="editBMPanel_folderRow hideable"
|
||||
control="editBMPanel_folderMenuList"/>
|
||||
@@ -47,7 +48,25 @@
|
||||
@@ -49,7 +50,25 @@
|
||||
class="expander-down panel-button"
|
||||
data-l10n-id="bookmark-overlay-folders-expander2"/>
|
||||
</hbox>
|
||||
|
||||
@@ -1,10 +1,12 @@
|
||||
diff --git a/browser/components/preferences/jar.mn b/browser/components/preferences/jar.mn
|
||||
index 78e38f98c1f69df31459fd4b6a119c93f6509c02..33abd46566146272da9f561e11ffa290d7000111 100644
|
||||
index aec7888f59eeb5dbffc62b861fe223159ac42586..a593f3015469c11c762ae01465964251a77ddb45 100644
|
||||
--- a/browser/components/preferences/jar.mn
|
||||
+++ b/browser/components/preferences/jar.mn
|
||||
@@ -54,3 +54,5 @@ browser.jar:
|
||||
content/browser/preferences/widgets/sync-device-name.mjs (widgets/sync-device-name/sync-device-name.mjs)
|
||||
content/browser/preferences/widgets/sync-engines-list.mjs (widgets/sync-engine-list/sync-engines-list.mjs)
|
||||
@@ -69,5 +69,7 @@ browser.jar:
|
||||
content/browser/preferences/widgets/sync-engines-list.css (widgets/sync-engine-list/sync-engines-list.css)
|
||||
content/browser/preferences/widgets/update-information.mjs (widgets/update-information/update-information.mjs)
|
||||
content/browser/preferences/widgets/update-information.css (widgets/update-information/update-information.css)
|
||||
+
|
||||
+ content/browser/preferences/zen-settings.js
|
||||
content/browser/preferences/widgets/update-state.mjs (widgets/update-state/update-state.mjs)
|
||||
content/browser/preferences/widgets/update-state.css (widgets/update-state/update-state.css)
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
diff --git a/browser/components/preferences/main.inc.xhtml b/browser/components/preferences/main.inc.xhtml
|
||||
index 6b96ff01e43087f8c609df17204441616b7013f3..df85ec789c54146b3a702169f33adf36c11b85da 100644
|
||||
index f6badc31b612c9198c56bb06751e9bbc4a0dd54b..5f9eca1ad0795ac38c02449c91e9f61bf6661252 100644
|
||||
--- a/browser/components/preferences/main.inc.xhtml
|
||||
+++ b/browser/components/preferences/main.inc.xhtml
|
||||
@@ -96,6 +96,7 @@
|
||||
@@ -98,6 +98,7 @@
|
||||
languages-customize-add.label,
|
||||
" />
|
||||
</hbox>
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
diff --git a/browser/components/preferences/main.js b/browser/components/preferences/main.js
|
||||
index 6f4cb34d1639ac76a6d4ca40f0d33ae6fb6bf565..1f336a09d6f2e367effdf26e8baf58b5686d252d 100644
|
||||
index c86e54bb6f5e00d9d7bdd81154857a5be97f909c..4035f6a667a361ad106e816a172342724a770435 100644
|
||||
--- a/browser/components/preferences/main.js
|
||||
+++ b/browser/components/preferences/main.js
|
||||
@@ -2537,6 +2537,11 @@ function createStartupConfig(hidden = false) {
|
||||
@@ -643,6 +643,11 @@ function createStartupConfig(hidden = false) {
|
||||
id: "browserRestoreSession",
|
||||
l10nId: "startup-restore-windows-and-tabs",
|
||||
},
|
||||
@@ -14,16 +14,16 @@ index 6f4cb34d1639ac76a6d4ca40f0d33ae6fb6bf565..1f336a09d6f2e367effdf26e8baf58b5
|
||||
{
|
||||
id: "windowsLaunchOnLogin",
|
||||
l10nId: "windows-launch-on-login",
|
||||
@@ -2578,7 +2583,7 @@ function createStartupConfig(hidden = false) {
|
||||
@@ -690,7 +695,7 @@ function createStartupConfig(hidden = false) {
|
||||
SettingGroupManager.registerGroups({
|
||||
defaultBrowser: createDefaultBrowserConfig(),
|
||||
startup: createStartupConfig(
|
||||
- Services.prefs.getBoolPref("browser.settings-redesign.enabled", false)
|
||||
- Services.prefs.getBoolPref("browser-settings-redesign.enabled", false)
|
||||
+ false
|
||||
),
|
||||
zoom: {
|
||||
l10nId: "preferences-zoom-header2",
|
||||
@@ -3393,7 +3398,7 @@ function getBundleForLocales(newLocales) {
|
||||
});
|
||||
|
||||
@@ -743,7 +748,7 @@ function getBundleForLocales(newLocales) {
|
||||
])
|
||||
);
|
||||
return new Localization(
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
diff --git a/browser/components/preferences/preferences.js b/browser/components/preferences/preferences.js
|
||||
index 9d13733318e7a147adee1e44f96570c94f4948df..fb625d8da021dc0cebd7a14ca47446a0632e8e7a 100644
|
||||
index 57add34d876fb885275f1147209c6fbeee367a7c..be0ab43b299317c0022a5e719f47a070c1574714 100644
|
||||
--- a/browser/components/preferences/preferences.js
|
||||
+++ b/browser/components/preferences/preferences.js
|
||||
@@ -121,6 +121,7 @@ ChromeUtils.defineLazyGetter(this, "gSubDialog", function () {
|
||||
@@ -132,6 +132,7 @@ ChromeUtils.defineLazyGetter(this, "gSubDialog", function () {
|
||||
styleSheets: [
|
||||
"chrome://browser/skin/preferences/dialog.css",
|
||||
"chrome://browser/skin/preferences/preferences.css",
|
||||
@@ -10,7 +10,25 @@ index 9d13733318e7a147adee1e44f96570c94f4948df..fb625d8da021dc0cebd7a14ca47446a0
|
||||
],
|
||||
resizeCallback: async ({ title, frame }) => {
|
||||
// Search within main document and highlight matched keyword.
|
||||
@@ -398,6 +399,10 @@ function init_all() {
|
||||
@@ -437,6 +438,8 @@ const CONFIG_PANES = Object.freeze({
|
||||
tabsBrowsing: {
|
||||
l10nId: "tabs-browsing-section",
|
||||
groupIds: [
|
||||
+ "defaultBrowserHome",
|
||||
+ "startupHome",
|
||||
"browserLayout",
|
||||
"tabs",
|
||||
"pageNavigation",
|
||||
@@ -477,7 +480,7 @@ function register_module(categoryName, categoryObject) {
|
||||
}
|
||||
this._initted = true;
|
||||
let template = document.getElementById("template-" + categoryName);
|
||||
- if (template && !srdSectionPrefs.all) {
|
||||
+ if (template && (!srdSectionPrefs.all || categoryName.startsWith("paneZen"))) {
|
||||
// Replace the template element with the nodes inside of it.
|
||||
template.replaceWith(template.content);
|
||||
|
||||
@@ -522,6 +525,10 @@ function init_all() {
|
||||
register_module("paneSearch", gSearchPane);
|
||||
register_module("panePrivacy", gPrivacyPane);
|
||||
register_module("paneContainers", gContainersPane);
|
||||
@@ -19,5 +37,17 @@ index 9d13733318e7a147adee1e44f96570c94f4948df..fb625d8da021dc0cebd7a14ca47446a0
|
||||
+ register_module("paneZenCKS", gZenCKSSettings);
|
||||
+ register_module("paneZenMarketplace", gZenMarketplaceManager);
|
||||
|
||||
if (ExperimentAPI.labsEnabled) {
|
||||
// Set hidden based on previous load's hidden value or if Nimbus is
|
||||
// Restore the cached Firefox Labs nav button visibility so it shows
|
||||
// immediately when recipes are expected to be available, before
|
||||
@@ -651,9 +658,9 @@ async function gotoPref(
|
||||
let redesignEnabled = srdSectionPrefs.all;
|
||||
let categories = document.getElementById("categories");
|
||||
const kDefaultCategoryInternalName = redesignEnabled
|
||||
- ? "paneSync"
|
||||
+ ? "paneTabsBrowsing"
|
||||
: "paneGeneral";
|
||||
- const kDefaultCategory = redesignEnabled ? "sync" : "general";
|
||||
+ const kDefaultCategory = redesignEnabled ? "tabsBrowsing" : "general";
|
||||
let hash = document.location.hash;
|
||||
let category = aCategory || hash.substring(1) || kDefaultCategoryInternalName;
|
||||
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
diff --git a/browser/components/preferences/preferences.xhtml b/browser/components/preferences/preferences.xhtml
|
||||
index 3c4b3225c672bcb172e7f946bc5f98d424e21e84..d10824470c564b6631333f197de897c21ccc19f5 100644
|
||||
index 9760a4a35b0b3bd21edec07a70c10bccc23e4a09..9f22146c259ea5b45005be660bfcb9ea2c1297ee 100644
|
||||
--- a/browser/components/preferences/preferences.xhtml
|
||||
+++ b/browser/components/preferences/preferences.xhtml
|
||||
@@ -42,6 +42,8 @@
|
||||
@@ -11,7 +11,7 @@ index 3c4b3225c672bcb172e7f946bc5f98d424e21e84..d10824470c564b6631333f197de897c2
|
||||
<link rel="localization" href="branding/brand.ftl"/>
|
||||
<link rel="localization" href="browser/browser.ftl"/>
|
||||
<!-- Used by fontbuilder.js -->
|
||||
@@ -126,6 +128,26 @@
|
||||
@@ -121,6 +123,26 @@
|
||||
iconsrc="chrome://browser/skin/preferences/category-general.svg"
|
||||
data-l10n-id="pane-general-title">
|
||||
</html:moz-page-nav-button>
|
||||
@@ -35,12 +35,12 @@ index 3c4b3225c672bcb172e7f946bc5f98d424e21e84..d10824470c564b6631333f197de897c2
|
||||
+ iconsrc="chrome://mozapps/skin/extensions/category-themes.svg"
|
||||
+ data-l10n-id="pane-zen-marketplace-title">
|
||||
+ </html:moz-page-nav-button>
|
||||
<html:moz-page-nav-button id="category-home"
|
||||
view="paneHome"
|
||||
iconsrc="chrome://browser/skin/home.svg"
|
||||
@@ -218,6 +240,10 @@
|
||||
<html:moz-page-nav-button id="category-sync"
|
||||
hidden="true"
|
||||
view="paneSync"
|
||||
@@ -253,6 +275,10 @@
|
||||
#include containers.inc.xhtml
|
||||
#include sync.inc.xhtml
|
||||
#include experimental.inc.xhtml
|
||||
#include moreFromMozilla.inc.xhtml
|
||||
+#include zenLooksAndFeel.inc.xhtml
|
||||
+#include zenKeyboardShortcuts.inc.xhtml
|
||||
|
||||
@@ -825,6 +825,7 @@ var zenIgnoreKeyboardShortcutIDs = [
|
||||
"key_enterFullScreen_compat",
|
||||
"key_exitFullScreen_old",
|
||||
"key_exitFullScreen_compat",
|
||||
"key_duplicateTab",
|
||||
];
|
||||
|
||||
var zenIgnoreKeyboardShortcutL10n = [
|
||||
@@ -944,6 +945,7 @@ var gZenCKSSettings = {
|
||||
});
|
||||
|
||||
input.addEventListener("blur", (event) => {
|
||||
this._currentActionID = null;
|
||||
const target = event.target;
|
||||
target.classList.remove(`${ZEN_CKS_INPUT_FIELD_CLASS}-editing`);
|
||||
if (!this._hasSafed) {
|
||||
@@ -1048,6 +1050,7 @@ var gZenCKSSettings = {
|
||||
input.classList.remove(`${ZEN_CKS_INPUT_FIELD_CLASS}-not-set`);
|
||||
input.classList.remove(`${ZEN_CKS_INPUT_FIELD_CLASS}-editing`);
|
||||
this._latestValidKey = null;
|
||||
this._currentActionID = null;
|
||||
return;
|
||||
} else if (shortcut == "Escape" && !modifiersActive) {
|
||||
const { hasConflicts, conflictShortcut } = gZenKeyboardShortcutsManager.checkForConflicts(
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
diff --git a/browser/components/search/SearchOneOffs.sys.mjs b/browser/components/search/SearchOneOffs.sys.mjs
|
||||
index 6317d8e22342bf50c82e5b526253d43406e74428..f233584b4a863309f71806cf7a3ee8e06f043429 100644
|
||||
index ca79f060e2104a56b42b9d813efb3567e183153e..7936263cc7d2796e1ec20dcfd1f14b2add568a64 100644
|
||||
--- a/browser/components/search/SearchOneOffs.sys.mjs
|
||||
+++ b/browser/components/search/SearchOneOffs.sys.mjs
|
||||
@@ -482,7 +482,7 @@ export class SearchOneOffs {
|
||||
@@ -481,7 +481,7 @@ export class SearchOneOffs {
|
||||
// For the search-bar, always show the one-off buttons where there is an
|
||||
// option to add an engine.
|
||||
let addEngineNeeded = isSearchBar && addEngines.length;
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
diff --git a/browser/components/sessionstore/SessionStore.sys.mjs b/browser/components/sessionstore/SessionStore.sys.mjs
|
||||
index 95f4960c3d8a2a4ca9bce24bcc54971877ee55ca..5bef8eeeb7cc26c930e3884e6eede6ea30f7d70a 100644
|
||||
index 183543c5f29ff4c879d3058e4c09faf376a69cb7..ab482c32cc697ccef82bf0aeaa0e3a1db40aecce 100644
|
||||
--- a/browser/components/sessionstore/SessionStore.sys.mjs
|
||||
+++ b/browser/components/sessionstore/SessionStore.sys.mjs
|
||||
@@ -129,6 +129,9 @@ const TAB_EVENTS = [
|
||||
@@ -21,7 +21,7 @@ index 95f4960c3d8a2a4ca9bce24bcc54971877ee55ca..5bef8eeeb7cc26c930e3884e6eede6ea
|
||||
});
|
||||
|
||||
ChromeUtils.defineLazyGetter(lazy, "blankURI", () => {
|
||||
@@ -1291,10 +1296,7 @@ var SessionStoreInternal = {
|
||||
@@ -1287,10 +1292,7 @@ var SessionStoreInternal = {
|
||||
*/
|
||||
get willAutoRestore() {
|
||||
return (
|
||||
@@ -33,7 +33,7 @@ index 95f4960c3d8a2a4ca9bce24bcc54971877ee55ca..5bef8eeeb7cc26c930e3884e6eede6ea
|
||||
);
|
||||
},
|
||||
|
||||
@@ -1970,6 +1972,9 @@ var SessionStoreInternal = {
|
||||
@@ -1965,6 +1967,9 @@ var SessionStoreInternal = {
|
||||
case "TabPinned":
|
||||
case "TabUnpinned":
|
||||
case "SwapDocShells":
|
||||
@@ -43,7 +43,7 @@ index 95f4960c3d8a2a4ca9bce24bcc54971877ee55ca..5bef8eeeb7cc26c930e3884e6eede6ea
|
||||
this.saveStateDelayed(win);
|
||||
break;
|
||||
case "TabGroupCreate":
|
||||
@@ -2083,6 +2088,10 @@ var SessionStoreInternal = {
|
||||
@@ -2074,6 +2079,10 @@ var SessionStoreInternal = {
|
||||
this._windows[aWindow.__SSi].isTaskbarTab = true;
|
||||
}
|
||||
|
||||
@@ -54,7 +54,7 @@ index 95f4960c3d8a2a4ca9bce24bcc54971877ee55ca..5bef8eeeb7cc26c930e3884e6eede6ea
|
||||
if (lazy.AIWindow.isAIWindowActiveAndEnabled(aWindow)) {
|
||||
this._windows[aWindow.__SSi].isAIWindow = true;
|
||||
}
|
||||
@@ -2119,7 +2128,7 @@ var SessionStoreInternal = {
|
||||
@@ -2110,7 +2119,7 @@ var SessionStoreInternal = {
|
||||
let isTaskbarTab = this._windows[aWindow.__SSi].isTaskbarTab;
|
||||
// A regular window is not a private window, taskbar tab window, or popup window
|
||||
let isRegularWindow =
|
||||
@@ -63,7 +63,7 @@ index 95f4960c3d8a2a4ca9bce24bcc54971877ee55ca..5bef8eeeb7cc26c930e3884e6eede6ea
|
||||
|
||||
// perform additional initialization when the first window is loading
|
||||
if (lazy.RunState.isStopped) {
|
||||
@@ -2131,7 +2140,7 @@ var SessionStoreInternal = {
|
||||
@@ -2122,7 +2131,7 @@ var SessionStoreInternal = {
|
||||
// to disk to NOW() to enforce a full interval before the next write.
|
||||
lazy.SessionSaver.updateLastSaveTime();
|
||||
|
||||
@@ -72,7 +72,7 @@ index 95f4960c3d8a2a4ca9bce24bcc54971877ee55ca..5bef8eeeb7cc26c930e3884e6eede6ea
|
||||
this._log.debug(
|
||||
"initializeWindow, the window is private or a web app. Saving SessionStartup.state for possibly restoring later"
|
||||
);
|
||||
@@ -2173,6 +2182,7 @@ var SessionStoreInternal = {
|
||||
@@ -2164,6 +2173,7 @@ var SessionStoreInternal = {
|
||||
null,
|
||||
"sessionstore-one-or-no-tab-restored"
|
||||
);
|
||||
@@ -80,7 +80,7 @@ index 95f4960c3d8a2a4ca9bce24bcc54971877ee55ca..5bef8eeeb7cc26c930e3884e6eede6ea
|
||||
this._deferredAllWindowsRestored.resolve();
|
||||
}
|
||||
// this window was opened by _openWindowWithState
|
||||
@@ -2222,7 +2232,6 @@ var SessionStoreInternal = {
|
||||
@@ -2213,7 +2223,6 @@ var SessionStoreInternal = {
|
||||
if (closedWindowState) {
|
||||
let newWindowState;
|
||||
if (
|
||||
@@ -88,7 +88,7 @@ index 95f4960c3d8a2a4ca9bce24bcc54971877ee55ca..5bef8eeeb7cc26c930e3884e6eede6ea
|
||||
!lazy.SessionStartup.willRestore()
|
||||
) {
|
||||
// We want to split the window up into pinned tabs and unpinned tabs.
|
||||
@@ -2258,6 +2267,7 @@ var SessionStoreInternal = {
|
||||
@@ -2249,6 +2258,7 @@ var SessionStoreInternal = {
|
||||
}
|
||||
|
||||
if (newWindowState) {
|
||||
@@ -96,7 +96,7 @@ index 95f4960c3d8a2a4ca9bce24bcc54971877ee55ca..5bef8eeeb7cc26c930e3884e6eede6ea
|
||||
// Ensure that the window state isn't hidden
|
||||
this._restoreCount = 1;
|
||||
let state = { windows: [newWindowState] };
|
||||
@@ -2286,6 +2296,15 @@ var SessionStoreInternal = {
|
||||
@@ -2277,6 +2287,15 @@ var SessionStoreInternal = {
|
||||
});
|
||||
this._shouldRestoreLastSession = false;
|
||||
}
|
||||
@@ -112,7 +112,7 @@ index 95f4960c3d8a2a4ca9bce24bcc54971877ee55ca..5bef8eeeb7cc26c930e3884e6eede6ea
|
||||
|
||||
if (this._restoreLastWindow && aWindow.toolbar.visible) {
|
||||
// always reset (if not a popup window)
|
||||
@@ -2436,7 +2455,7 @@ var SessionStoreInternal = {
|
||||
@@ -2427,7 +2446,7 @@ var SessionStoreInternal = {
|
||||
|
||||
var tabbrowser = aWindow.gBrowser;
|
||||
|
||||
@@ -121,7 +121,7 @@ index 95f4960c3d8a2a4ca9bce24bcc54971877ee55ca..5bef8eeeb7cc26c930e3884e6eede6ea
|
||||
|
||||
TAB_EVENTS.forEach(function (aEvent) {
|
||||
tabbrowser.tabContainer.removeEventListener(aEvent, this, true);
|
||||
@@ -2487,7 +2506,7 @@ var SessionStoreInternal = {
|
||||
@@ -2478,7 +2497,7 @@ var SessionStoreInternal = {
|
||||
|
||||
let isLastRegularWindow =
|
||||
Object.values(this._windows).filter(
|
||||
@@ -130,7 +130,7 @@ index 95f4960c3d8a2a4ca9bce24bcc54971877ee55ca..5bef8eeeb7cc26c930e3884e6eede6ea
|
||||
).length == 1;
|
||||
this._log.debug(
|
||||
`onClose, closing window isLastRegularWindow? ${isLastRegularWindow}`
|
||||
@@ -2544,8 +2563,8 @@ var SessionStoreInternal = {
|
||||
@@ -2535,8 +2554,8 @@ var SessionStoreInternal = {
|
||||
// 2) Flush the window.
|
||||
// 3) When the flush is complete, revisit our decision to store the window
|
||||
// in _closedWindows, and add/remove as necessary.
|
||||
@@ -141,7 +141,7 @@ index 95f4960c3d8a2a4ca9bce24bcc54971877ee55ca..5bef8eeeb7cc26c930e3884e6eede6ea
|
||||
}
|
||||
|
||||
completionPromise = lazy.TabStateFlusher.flushWindow(aWindow).then(() => {
|
||||
@@ -2565,8 +2584,9 @@ var SessionStoreInternal = {
|
||||
@@ -2556,8 +2575,9 @@ var SessionStoreInternal = {
|
||||
|
||||
// Save non-private windows if they have at
|
||||
// least one saveable tab or are the last window.
|
||||
@@ -153,7 +153,7 @@ index 95f4960c3d8a2a4ca9bce24bcc54971877ee55ca..5bef8eeeb7cc26c930e3884e6eede6ea
|
||||
|
||||
if (!isLastWindow && winData.closedId > -1) {
|
||||
this._addClosedAction(
|
||||
@@ -2642,7 +2662,7 @@ var SessionStoreInternal = {
|
||||
@@ -2633,7 +2653,7 @@ var SessionStoreInternal = {
|
||||
* to call this method again asynchronously (for example, after
|
||||
* a window flush).
|
||||
*/
|
||||
@@ -162,7 +162,7 @@ index 95f4960c3d8a2a4ca9bce24bcc54971877ee55ca..5bef8eeeb7cc26c930e3884e6eede6ea
|
||||
// Make sure SessionStore is still running, and make sure that we
|
||||
// haven't chosen to forget this window.
|
||||
if (
|
||||
@@ -2659,6 +2679,7 @@ var SessionStoreInternal = {
|
||||
@@ -2650,6 +2670,7 @@ var SessionStoreInternal = {
|
||||
// _closedWindows from a previous call to this function.
|
||||
let winIndex = this._closedWindows.indexOf(winData);
|
||||
let alreadyStored = winIndex != -1;
|
||||
@@ -170,7 +170,7 @@ index 95f4960c3d8a2a4ca9bce24bcc54971877ee55ca..5bef8eeeb7cc26c930e3884e6eede6ea
|
||||
// If sidebar command is truthy, i.e. sidebar is open, store sidebar settings
|
||||
let shouldStore = hasSaveableTabs || isLastWindow;
|
||||
|
||||
@@ -3480,7 +3501,7 @@ var SessionStoreInternal = {
|
||||
@@ -3467,7 +3488,7 @@ var SessionStoreInternal = {
|
||||
if (!isPrivateWindow && tabState.isPrivate) {
|
||||
return;
|
||||
}
|
||||
@@ -179,7 +179,7 @@ index 95f4960c3d8a2a4ca9bce24bcc54971877ee55ca..5bef8eeeb7cc26c930e3884e6eede6ea
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -4220,6 +4241,12 @@ var SessionStoreInternal = {
|
||||
@@ -4206,6 +4227,12 @@ var SessionStoreInternal = {
|
||||
Math.min(tabState.index, tabState.entries.length)
|
||||
);
|
||||
tabState.pinned = false;
|
||||
@@ -192,7 +192,7 @@ index 95f4960c3d8a2a4ca9bce24bcc54971877ee55ca..5bef8eeeb7cc26c930e3884e6eede6ea
|
||||
|
||||
if (inBackground === false) {
|
||||
aWindow.gBrowser.selectedTab = newTab;
|
||||
@@ -4656,6 +4683,8 @@ var SessionStoreInternal = {
|
||||
@@ -4642,6 +4669,8 @@ var SessionStoreInternal = {
|
||||
// Append the tab if we're opening into a different window,
|
||||
tabIndex: aSource == aTargetWindow ? pos : Infinity,
|
||||
pinned: state.pinned,
|
||||
@@ -201,7 +201,7 @@ index 95f4960c3d8a2a4ca9bce24bcc54971877ee55ca..5bef8eeeb7cc26c930e3884e6eede6ea
|
||||
userContextId: state.userContextId,
|
||||
skipLoad: true,
|
||||
preferredRemoteType,
|
||||
@@ -5160,9 +5189,10 @@ var SessionStoreInternal = {
|
||||
@@ -5146,9 +5175,10 @@ var SessionStoreInternal = {
|
||||
if (activePageData.title && activePageData.title != activePageData.url) {
|
||||
win.gBrowser.setInitialTabTitle(tab, activePageData.title, {
|
||||
isContentTitle: true,
|
||||
@@ -213,7 +213,7 @@ index 95f4960c3d8a2a4ca9bce24bcc54971877ee55ca..5bef8eeeb7cc26c930e3884e6eede6ea
|
||||
}
|
||||
}
|
||||
|
||||
@@ -5527,7 +5557,7 @@ var SessionStoreInternal = {
|
||||
@@ -5513,7 +5543,7 @@ var SessionStoreInternal = {
|
||||
|
||||
for (let i = tabbrowser.pinnedTabCount; i < tabbrowser.tabs.length; i++) {
|
||||
let tab = tabbrowser.tabs[i];
|
||||
@@ -222,7 +222,7 @@ index 95f4960c3d8a2a4ca9bce24bcc54971877ee55ca..5bef8eeeb7cc26c930e3884e6eede6ea
|
||||
removableTabs.push(tab);
|
||||
}
|
||||
}
|
||||
@@ -5640,7 +5670,7 @@ var SessionStoreInternal = {
|
||||
@@ -5626,7 +5656,7 @@ var SessionStoreInternal = {
|
||||
|
||||
// collect the data for all windows
|
||||
for (ix in this._windows) {
|
||||
@@ -231,7 +231,7 @@ index 95f4960c3d8a2a4ca9bce24bcc54971877ee55ca..5bef8eeeb7cc26c930e3884e6eede6ea
|
||||
// window data is still in _statesToRestore
|
||||
continue;
|
||||
}
|
||||
@@ -5784,11 +5814,12 @@ var SessionStoreInternal = {
|
||||
@@ -5770,11 +5800,12 @@ var SessionStoreInternal = {
|
||||
}
|
||||
|
||||
let tabbrowser = aWindow.gBrowser;
|
||||
@@ -245,7 +245,7 @@ index 95f4960c3d8a2a4ca9bce24bcc54971877ee55ca..5bef8eeeb7cc26c930e3884e6eede6ea
|
||||
// update the internal state data for this window
|
||||
for (let tab of tabs) {
|
||||
if (tab == aWindow.FirefoxViewHandler.tab) {
|
||||
@@ -5799,6 +5830,9 @@ var SessionStoreInternal = {
|
||||
@@ -5785,6 +5816,9 @@ var SessionStoreInternal = {
|
||||
tabsData.push(tabData);
|
||||
}
|
||||
|
||||
@@ -255,7 +255,7 @@ index 95f4960c3d8a2a4ca9bce24bcc54971877ee55ca..5bef8eeeb7cc26c930e3884e6eede6ea
|
||||
// update tab group state for this window
|
||||
winData.groups = [];
|
||||
for (let tabGroup of aWindow.gBrowser.tabGroups) {
|
||||
@@ -5815,7 +5849,7 @@ var SessionStoreInternal = {
|
||||
@@ -5801,7 +5835,7 @@ var SessionStoreInternal = {
|
||||
// a window is closed, point to the first item in the tab strip instead (it will never be the Firefox View tab,
|
||||
// since it's only inserted into the tab strip after it's selected).
|
||||
if (aWindow.FirefoxViewHandler.tab?.selected) {
|
||||
@@ -264,7 +264,7 @@ index 95f4960c3d8a2a4ca9bce24bcc54971877ee55ca..5bef8eeeb7cc26c930e3884e6eede6ea
|
||||
winData.title = tabbrowser.tabs[0].label;
|
||||
}
|
||||
winData.selected = selectedIndex;
|
||||
@@ -6017,8 +6051,8 @@ var SessionStoreInternal = {
|
||||
@@ -6003,8 +6037,8 @@ var SessionStoreInternal = {
|
||||
// selectTab represents.
|
||||
let selectTab = 0;
|
||||
if (overwriteTabs) {
|
||||
@@ -275,7 +275,7 @@ index 95f4960c3d8a2a4ca9bce24bcc54971877ee55ca..5bef8eeeb7cc26c930e3884e6eede6ea
|
||||
selectTab = Math.min(selectTab, winData.tabs.length);
|
||||
}
|
||||
|
||||
@@ -6040,6 +6074,7 @@ var SessionStoreInternal = {
|
||||
@@ -6026,6 +6060,7 @@ var SessionStoreInternal = {
|
||||
if (overwriteTabs) {
|
||||
for (let i = tabbrowser.browsers.length - 1; i >= 0; i--) {
|
||||
if (!tabbrowser.tabs[i].selected) {
|
||||
@@ -283,7 +283,7 @@ index 95f4960c3d8a2a4ca9bce24bcc54971877ee55ca..5bef8eeeb7cc26c930e3884e6eede6ea
|
||||
tabbrowser.removeTab(tabbrowser.tabs[i]);
|
||||
}
|
||||
}
|
||||
@@ -6074,6 +6109,12 @@ var SessionStoreInternal = {
|
||||
@@ -6060,6 +6095,12 @@ var SessionStoreInternal = {
|
||||
savedTabGroup => !openTabGroupIdsInWindow.has(savedTabGroup.id)
|
||||
);
|
||||
}
|
||||
@@ -296,7 +296,7 @@ index 95f4960c3d8a2a4ca9bce24bcc54971877ee55ca..5bef8eeeb7cc26c930e3884e6eede6ea
|
||||
|
||||
// Move the originally open tabs to the end.
|
||||
if (initialTabs) {
|
||||
@@ -6640,6 +6681,25 @@ var SessionStoreInternal = {
|
||||
@@ -6626,6 +6667,25 @@ var SessionStoreInternal = {
|
||||
|
||||
// Most of tabData has been restored, now continue with restoring
|
||||
// attributes that may trigger external events.
|
||||
@@ -322,7 +322,7 @@ index 95f4960c3d8a2a4ca9bce24bcc54971877ee55ca..5bef8eeeb7cc26c930e3884e6eede6ea
|
||||
|
||||
if (tabData.pinned) {
|
||||
tabbrowser.pinTab(tab);
|
||||
@@ -6807,6 +6867,9 @@ var SessionStoreInternal = {
|
||||
@@ -6793,6 +6853,9 @@ var SessionStoreInternal = {
|
||||
aWindow.gURLBar.readOnly = false;
|
||||
}
|
||||
}
|
||||
@@ -332,7 +332,7 @@ index 95f4960c3d8a2a4ca9bce24bcc54971877ee55ca..5bef8eeeb7cc26c930e3884e6eede6ea
|
||||
|
||||
let promiseParts = Promise.withResolvers();
|
||||
aWindow.setTimeout(() => {
|
||||
@@ -7602,7 +7665,7 @@ var SessionStoreInternal = {
|
||||
@@ -7588,7 +7651,7 @@ var SessionStoreInternal = {
|
||||
|
||||
let groupsToSave = new Map();
|
||||
for (let tIndex = 0; tIndex < window.tabs.length; ) {
|
||||
@@ -341,7 +341,7 @@ index 95f4960c3d8a2a4ca9bce24bcc54971877ee55ca..5bef8eeeb7cc26c930e3884e6eede6ea
|
||||
// Adjust window.selected
|
||||
if (tIndex + 1 < window.selected) {
|
||||
window.selected -= 1;
|
||||
@@ -7617,7 +7680,7 @@ var SessionStoreInternal = {
|
||||
@@ -7603,7 +7666,7 @@ var SessionStoreInternal = {
|
||||
);
|
||||
// We don't want to increment tIndex here.
|
||||
continue;
|
||||
@@ -350,7 +350,7 @@ index 95f4960c3d8a2a4ca9bce24bcc54971877ee55ca..5bef8eeeb7cc26c930e3884e6eede6ea
|
||||
// Convert any open groups into saved groups.
|
||||
let groupStateToSave = window.groups.find(
|
||||
groupState => groupState.id == window.tabs[tIndex].groupId
|
||||
@@ -8076,7 +8139,6 @@ var SessionStoreInternal = {
|
||||
@@ -8062,7 +8125,6 @@ var SessionStoreInternal = {
|
||||
timer.initWithCallback(
|
||||
function () {
|
||||
if (beats <= 0) {
|
||||
@@ -358,7 +358,7 @@ index 95f4960c3d8a2a4ca9bce24bcc54971877ee55ca..5bef8eeeb7cc26c930e3884e6eede6ea
|
||||
Glean.sessionRestore.shutdownFlushAllOutcomes.timed_out.add(1);
|
||||
deferred.resolve();
|
||||
}
|
||||
@@ -8554,6 +8616,7 @@ var SessionStoreInternal = {
|
||||
@@ -8540,6 +8602,7 @@ var SessionStoreInternal = {
|
||||
if (
|
||||
!savedTabGroupState.tabs.length ||
|
||||
this.getSavedTabGroup(savedTabGroupState.id)
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
diff --git a/browser/components/sessionstore/TabState.sys.mjs b/browser/components/sessionstore/TabState.sys.mjs
|
||||
index eb24c3ffdd2cfb33379aca993af5171fdb91ac2c..15d3fbff397df23f112355e22ca5dba5bf29528f 100644
|
||||
index 4ba4dda363b602cb6f4445ef056f2f9abb1b0e1e..6b4b407e05e26faca69d9d7ac6f31510620898fe 100644
|
||||
--- a/browser/components/sessionstore/TabState.sys.mjs
|
||||
+++ b/browser/components/sessionstore/TabState.sys.mjs
|
||||
@@ -99,7 +99,25 @@ class _TabState {
|
||||
@@ -99,10 +99,28 @@ class _TabState {
|
||||
}
|
||||
}
|
||||
|
||||
@@ -21,8 +21,11 @@ index eb24c3ffdd2cfb33379aca993af5171fdb91ac2c..15d3fbff397df23f112355e22ca5dba5
|
||||
+ tabData._zenIsActiveTab = tab._zenContentsVisible;
|
||||
+ tabData.zenLiveFolderItemId = tab.getAttribute("zen-live-folder-item-id");
|
||||
+
|
||||
tabData.searchMode = tab.ownerGlobal.gURLBar.getSearchMode(browser, true);
|
||||
+ if (tabData.searchMode?.source === tab.ownerGlobal.UrlbarUtils.RESULT_SOURCE.ZEN_ACTIONS) {
|
||||
tabData.searchMode = tab.documentGlobal.gURLBar.getSearchMode(
|
||||
browser,
|
||||
true
|
||||
);
|
||||
+ if (tabData.searchMode?.source === tab.documentGlobal.UrlbarUtils.RESULT_SOURCE.ZEN_ACTIONS) {
|
||||
+ delete tabData.searchMode;
|
||||
+ }
|
||||
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
diff --git a/browser/components/sidebar/browser-sidebar.js b/browser/components/sidebar/browser-sidebar.js
|
||||
index 2c13f19ec4f962ce3ecaface0ae5d00c50ca913f..eb696819a1af4cfae6352fc5696fd95590bed342 100644
|
||||
index ef7b67413392840720c8f09b6f22b0413ccf4435..ebbc15722ffb410050dd1923e8bb49d8cd5b6a9e 100644
|
||||
--- a/browser/components/sidebar/browser-sidebar.js
|
||||
+++ b/browser/components/sidebar/browser-sidebar.js
|
||||
@@ -834,7 +834,7 @@ var SidebarController = {
|
||||
@@ -850,7 +850,7 @@ var SidebarController = {
|
||||
setPosition() {
|
||||
// First reset all ordinals to match DOM ordering.
|
||||
let contentArea = document.getElementById("tabbrowser-tabbox");
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
diff --git a/browser/components/tabbrowser/AsyncTabSwitcher.sys.mjs b/browser/components/tabbrowser/AsyncTabSwitcher.sys.mjs
|
||||
index eebff0f59df42d3ef075f3eea1bd9269c47ba80d..6ab43a810f4cb61eedc02bb42026f6b5e282e785 100644
|
||||
index 577e27598597de27116153be1ad149facd721e41..eeca455aad8323ef24957af076f131cb70d66e7d 100644
|
||||
--- a/browser/components/tabbrowser/AsyncTabSwitcher.sys.mjs
|
||||
+++ b/browser/components/tabbrowser/AsyncTabSwitcher.sys.mjs
|
||||
@@ -938,6 +938,7 @@ export class AsyncTabSwitcher {
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
diff --git a/browser/components/tabbrowser/TabsList.sys.mjs b/browser/components/tabbrowser/TabsList.sys.mjs
|
||||
index 4de5139f404fab227874f626bda27e2a32cf87a0..7574e6db1606c72e8da3141d4a8deec727376af8 100644
|
||||
index 58f91dd9f80aa34ff8d8095cbaf5ae7a6c8dc1e1..c4c9ad5d93053f5fc726a0b10fa8d56c6bbc4003 100644
|
||||
--- a/browser/components/tabbrowser/TabsList.sys.mjs
|
||||
+++ b/browser/components/tabbrowser/TabsList.sys.mjs
|
||||
@@ -87,7 +87,7 @@ class TabsListBase {
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
diff --git a/browser/components/tabbrowser/content/drag-and-drop.js b/browser/components/tabbrowser/content/drag-and-drop.js
|
||||
index ea4f83fad1757f073ea1bbe5c93a4ebe5ecc0abe..904e604e28c96757fabf0dd3a749c85280e74993 100644
|
||||
index 8bb1219962a1368f50b53c61041f135c68e35f31..8e72441d26883cbef7a352b00c0fe2b15a030046 100644
|
||||
--- a/browser/components/tabbrowser/content/drag-and-drop.js
|
||||
+++ b/browser/components/tabbrowser/content/drag-and-drop.js
|
||||
@@ -35,6 +35,9 @@
|
||||
@@ -159,7 +159,7 @@ index ea4f83fad1757f073ea1bbe5c93a4ebe5ecc0abe..904e604e28c96757fabf0dd3a749c852
|
||||
if (
|
||||
dt.mozUserCancelled ||
|
||||
dt.dropEffect != "none" ||
|
||||
@@ -918,11 +938,10 @@
|
||||
@@ -927,11 +947,10 @@
|
||||
return this.#getHorizontalScrollboxDragTarget(event, ignoreSides);
|
||||
}
|
||||
while (target) {
|
||||
@@ -175,7 +175,7 @@ index ea4f83fad1757f073ea1bbe5c93a4ebe5ecc0abe..904e604e28c96757fabf0dd3a749c852
|
||||
break;
|
||||
}
|
||||
target = target.parentNode;
|
||||
@@ -952,6 +971,9 @@
|
||||
@@ -961,6 +980,9 @@
|
||||
return null;
|
||||
}
|
||||
}
|
||||
@@ -185,7 +185,7 @@ index ea4f83fad1757f073ea1bbe5c93a4ebe5ecc0abe..904e604e28c96757fabf0dd3a749c852
|
||||
return target;
|
||||
}
|
||||
|
||||
@@ -1011,7 +1033,8 @@
|
||||
@@ -1014,7 +1036,8 @@
|
||||
isTabGroupLabel(draggedTab) &&
|
||||
draggedTab._dragData?.expandGroupOnDrop
|
||||
) {
|
||||
@@ -195,7 +195,7 @@ index ea4f83fad1757f073ea1bbe5c93a4ebe5ecc0abe..904e604e28c96757fabf0dd3a749c852
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1195,7 +1218,6 @@
|
||||
@@ -1206,7 +1229,6 @@
|
||||
// using updateDragImage. On Linux, we can use a panel.
|
||||
if (platform == "win" || platform == "macosx") {
|
||||
captureListener = function () {
|
||||
@@ -203,7 +203,7 @@ index ea4f83fad1757f073ea1bbe5c93a4ebe5ecc0abe..904e604e28c96757fabf0dd3a749c852
|
||||
};
|
||||
} else {
|
||||
// Create a panel to use it in setDragImage
|
||||
@@ -1233,7 +1255,6 @@
|
||||
@@ -1244,7 +1266,6 @@
|
||||
);
|
||||
dragImageOffset = dragImageOffset * scale;
|
||||
}
|
||||
@@ -211,7 +211,7 @@ index ea4f83fad1757f073ea1bbe5c93a4ebe5ecc0abe..904e604e28c96757fabf0dd3a749c852
|
||||
|
||||
// _dragData.offsetX/Y give the coordinates that the mouse should be
|
||||
// positioned relative to the corner of the new window created upon
|
||||
@@ -1252,7 +1273,7 @@
|
||||
@@ -1263,7 +1284,7 @@
|
||||
let dropEffect = this.getDropEffectForTabDrag(event);
|
||||
let isMovingInTabStrip = !fromTabList && dropEffect == "move";
|
||||
let collapseTabGroupDuringDrag =
|
||||
@@ -220,7 +220,7 @@ index ea4f83fad1757f073ea1bbe5c93a4ebe5ecc0abe..904e604e28c96757fabf0dd3a749c852
|
||||
|
||||
tab._dragData = {
|
||||
offsetX: this._tabbrowserTabs.verticalMode
|
||||
@@ -1262,7 +1283,7 @@
|
||||
@@ -1273,7 +1294,7 @@
|
||||
? event.screenY - window.screenY - tabOffset
|
||||
: event.screenY - window.screenY,
|
||||
scrollPos:
|
||||
@@ -229,7 +229,7 @@ index ea4f83fad1757f073ea1bbe5c93a4ebe5ecc0abe..904e604e28c96757fabf0dd3a749c852
|
||||
? this._tabbrowserTabs.pinnedTabsContainer.scrollPosition
|
||||
: this._tabbrowserTabs.arrowScrollbox.scrollPosition,
|
||||
screenX: event.screenX,
|
||||
@@ -1309,6 +1330,7 @@
|
||||
@@ -1320,6 +1341,7 @@
|
||||
if (tabStripItemElement.hasAttribute("dragtarget")) {
|
||||
return;
|
||||
}
|
||||
@@ -237,7 +237,7 @@ index ea4f83fad1757f073ea1bbe5c93a4ebe5ecc0abe..904e604e28c96757fabf0dd3a749c852
|
||||
let isPinned = tab.pinned;
|
||||
let dragAndDropElements = this._tabbrowserTabs.dragAndDropElements;
|
||||
let isGrid = this._tabbrowserTabs.isContainerVerticalPinnedGrid(tab);
|
||||
@@ -1675,23 +1697,6 @@
|
||||
@@ -1686,23 +1708,6 @@
|
||||
|
||||
// Slide the relevant tabs to their new position.
|
||||
// non-moving tabs adjust for RTL
|
||||
@@ -261,7 +261,7 @@ index ea4f83fad1757f073ea1bbe5c93a4ebe5ecc0abe..904e604e28c96757fabf0dd3a749c852
|
||||
// moving tabs don't adjust for RTL
|
||||
for (let item of selectedElements) {
|
||||
if (
|
||||
@@ -1740,7 +1745,6 @@
|
||||
@@ -1751,7 +1756,6 @@
|
||||
for (let item of this._tabbrowserTabs.dragAndDropElements) {
|
||||
delete item._moveTogetherSelectedTabsData;
|
||||
item = elementToMove(item);
|
||||
@@ -269,7 +269,7 @@ index ea4f83fad1757f073ea1bbe5c93a4ebe5ecc0abe..904e604e28c96757fabf0dd3a749c852
|
||||
item.removeAttribute("multiselected-move-together");
|
||||
}
|
||||
}
|
||||
@@ -2587,7 +2591,6 @@
|
||||
@@ -2598,7 +2602,6 @@
|
||||
tab.style.top = "";
|
||||
tab.style.maxWidth = "";
|
||||
tab.style.pointerEvents = "";
|
||||
@@ -277,7 +277,7 @@ index ea4f83fad1757f073ea1bbe5c93a4ebe5ecc0abe..904e604e28c96757fabf0dd3a749c852
|
||||
tab.removeAttribute("small-stack");
|
||||
tab.removeAttribute("big-stack");
|
||||
}
|
||||
@@ -2596,11 +2599,9 @@
|
||||
@@ -2607,11 +2610,9 @@
|
||||
)) {
|
||||
label.style.width = "";
|
||||
label.style.maxWidth = "";
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
diff --git a/browser/components/tabbrowser/content/tab.js b/browser/components/tabbrowser/content/tab.js
|
||||
index b9381999a77ecacdb95c69494ac8972e9f13d14d..a210b53bb46373f8bab532a00b25301d645641cd 100644
|
||||
index 8f2ebf3a0bd4e2af01cf41024b16bd491e8ed961..27721e26c3cd8cb066b462dedfa4ce785ca5c2c3 100644
|
||||
--- a/browser/components/tabbrowser/content/tab.js
|
||||
+++ b/browser/components/tabbrowser/content/tab.js
|
||||
@@ -21,6 +21,7 @@
|
||||
@@ -10,10 +10,10 @@ index b9381999a77ecacdb95c69494ac8972e9f13d14d..a210b53bb46373f8bab532a00b25301d
|
||||
<stack class="tab-icon-stack">
|
||||
<hbox class="tab-throbber"/>
|
||||
<hbox class="tab-icon-pending"/>
|
||||
@@ -38,9 +39,11 @@
|
||||
<hbox class="tab-secondary-label">
|
||||
<label class="tab-icon-sound-label tab-icon-sound-pip-label" data-l10n-id="browser-tab-audio-pip" role="presentation"/>
|
||||
</hbox>
|
||||
@@ -35,9 +36,11 @@
|
||||
pack="center"
|
||||
flex="1">
|
||||
<label class="tab-text tab-label" role="presentation"/>
|
||||
+ <label class="zen-tab-sublabel" data-l10n-id="zen-tab-sublabel" data-l10n-args='{"tabSubtitle": "zen-default-pinned"}' role="presentation"/>
|
||||
</vbox>
|
||||
<image class="tab-note-icon" role="presentation"/>
|
||||
@@ -22,7 +22,7 @@ index b9381999a77ecacdb95c69494ac8972e9f13d14d..a210b53bb46373f8bab532a00b25301d
|
||||
</hbox>
|
||||
</stack>
|
||||
`;
|
||||
@@ -87,7 +90,7 @@
|
||||
@@ -84,7 +87,7 @@
|
||||
".tab-content":
|
||||
"pinned,selected=visuallyselected,multiselected,titlechanged,attention",
|
||||
".tab-icon-stack":
|
||||
@@ -31,7 +31,7 @@ index b9381999a77ecacdb95c69494ac8972e9f13d14d..a210b53bb46373f8bab532a00b25301d
|
||||
".tab-throbber":
|
||||
"fadein,pinned,busy,progress,selected=visuallyselected",
|
||||
".tab-icon-pending":
|
||||
@@ -96,9 +99,9 @@
|
||||
@@ -93,9 +96,9 @@
|
||||
"src=image,requestcontextid,fadein,pinned,selected=visuallyselected,busy,crashed,sharing,pictureinpicture,pending,discarded",
|
||||
".tab-sharing-icon-overlay": "sharing,selected=visuallyselected,pinned",
|
||||
".tab-icon-overlay":
|
||||
@@ -43,7 +43,7 @@ index b9381999a77ecacdb95c69494ac8972e9f13d14d..a210b53bb46373f8bab532a00b25301d
|
||||
".tab-label-container":
|
||||
"pinned,selected=visuallyselected,labeldirection",
|
||||
".tab-label":
|
||||
@@ -189,7 +192,7 @@
|
||||
@@ -184,7 +187,7 @@
|
||||
}
|
||||
|
||||
set _visuallySelected(val) {
|
||||
@@ -52,7 +52,7 @@ index b9381999a77ecacdb95c69494ac8972e9f13d14d..a210b53bb46373f8bab532a00b25301d
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -225,11 +228,25 @@
|
||||
@@ -220,11 +223,25 @@
|
||||
}
|
||||
|
||||
get visible() {
|
||||
@@ -83,7 +83,7 @@ index b9381999a77ecacdb95c69494ac8972e9f13d14d..a210b53bb46373f8bab532a00b25301d
|
||||
}
|
||||
|
||||
get hidden() {
|
||||
@@ -308,7 +325,7 @@
|
||||
@@ -303,7 +320,7 @@
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -92,7 +92,7 @@ index b9381999a77ecacdb95c69494ac8972e9f13d14d..a210b53bb46373f8bab532a00b25301d
|
||||
}
|
||||
|
||||
get lastAccessed() {
|
||||
@@ -393,7 +410,18 @@
|
||||
@@ -388,7 +405,18 @@
|
||||
}
|
||||
|
||||
get group() {
|
||||
@@ -112,7 +112,7 @@ index b9381999a77ecacdb95c69494ac8972e9f13d14d..a210b53bb46373f8bab532a00b25301d
|
||||
}
|
||||
|
||||
get splitview() {
|
||||
@@ -475,6 +503,10 @@
|
||||
@@ -470,6 +498,10 @@
|
||||
}
|
||||
}
|
||||
|
||||
@@ -123,7 +123,7 @@ index b9381999a77ecacdb95c69494ac8972e9f13d14d..a210b53bb46373f8bab532a00b25301d
|
||||
// If the previous target wasn't part of this tab then this is a mouseenter event.
|
||||
if (!this.contains(event.relatedTarget)) {
|
||||
this._mouseenter();
|
||||
@@ -504,6 +536,7 @@
|
||||
@@ -499,6 +531,7 @@
|
||||
if (!this.contains(event.relatedTarget)) {
|
||||
this._mouseleave();
|
||||
}
|
||||
@@ -131,7 +131,7 @@ index b9381999a77ecacdb95c69494ac8972e9f13d14d..a210b53bb46373f8bab532a00b25301d
|
||||
}
|
||||
|
||||
on_dragstart(event) {
|
||||
@@ -538,6 +571,8 @@
|
||||
@@ -533,6 +566,8 @@
|
||||
this.style.MozUserFocus = "ignore";
|
||||
} else if (
|
||||
event.target.classList.contains("tab-close-button") ||
|
||||
@@ -140,7 +140,7 @@ index b9381999a77ecacdb95c69494ac8972e9f13d14d..a210b53bb46373f8bab532a00b25301d
|
||||
event.target.classList.contains("tab-icon-overlay") ||
|
||||
event.target.classList.contains("tab-audio-button")
|
||||
) {
|
||||
@@ -572,7 +607,7 @@
|
||||
@@ -567,7 +602,7 @@
|
||||
}
|
||||
} else if (
|
||||
event.altKey &&
|
||||
@@ -149,7 +149,7 @@ index b9381999a77ecacdb95c69494ac8972e9f13d14d..a210b53bb46373f8bab532a00b25301d
|
||||
) {
|
||||
eventMaySelectTab = false;
|
||||
} else if (!this.selected && this.multiselected) {
|
||||
@@ -597,6 +632,10 @@
|
||||
@@ -592,6 +627,10 @@
|
||||
this.style.MozUserFocus = "";
|
||||
}
|
||||
|
||||
@@ -160,7 +160,7 @@ index b9381999a77ecacdb95c69494ac8972e9f13d14d..a210b53bb46373f8bab532a00b25301d
|
||||
on_click(event) {
|
||||
if (event.button != 0) {
|
||||
return;
|
||||
@@ -620,14 +659,31 @@
|
||||
@@ -615,14 +654,31 @@
|
||||
trigger: "alt_click",
|
||||
});
|
||||
}
|
||||
@@ -193,7 +193,7 @@ index b9381999a77ecacdb95c69494ac8972e9f13d14d..a210b53bb46373f8bab532a00b25301d
|
||||
gBrowser.multiSelectedTabsCount > 0 &&
|
||||
!event.target.classList.contains("tab-close-button") &&
|
||||
!event.target.classList.contains("tab-icon-overlay") &&
|
||||
@@ -639,8 +695,9 @@
|
||||
@@ -634,8 +690,9 @@
|
||||
}
|
||||
|
||||
if (
|
||||
@@ -205,7 +205,7 @@ index b9381999a77ecacdb95c69494ac8972e9f13d14d..a210b53bb46373f8bab532a00b25301d
|
||||
) {
|
||||
if (this.activeMediaBlocked) {
|
||||
if (this.multiselected) {
|
||||
@@ -658,7 +715,7 @@
|
||||
@@ -653,7 +710,7 @@
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -214,7 +214,7 @@ index b9381999a77ecacdb95c69494ac8972e9f13d14d..a210b53bb46373f8bab532a00b25301d
|
||||
if (this.multiselected) {
|
||||
gBrowser.removeMultiSelectedTabs(
|
||||
lazy.TabMetrics.userTriggeredContext(
|
||||
@@ -678,6 +735,14 @@
|
||||
@@ -673,6 +730,14 @@
|
||||
// (see tabbrowser-tabs 'click' handler).
|
||||
gBrowser.tabContainer._blockDblClick = true;
|
||||
}
|
||||
@@ -229,7 +229,7 @@ index b9381999a77ecacdb95c69494ac8972e9f13d14d..a210b53bb46373f8bab532a00b25301d
|
||||
}
|
||||
|
||||
on_dblclick(event) {
|
||||
@@ -701,6 +766,8 @@
|
||||
@@ -696,6 +761,8 @@
|
||||
animate: true,
|
||||
triggeringEvent: event,
|
||||
});
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
diff --git a/browser/components/tabbrowser/content/tabbrowser.js b/browser/components/tabbrowser/content/tabbrowser.js
|
||||
index 43fb79a3060e20f671ae6ffc26350c7abf497702..146b1559b8430773bd4ec173a8f4fe88f4eec282 100644
|
||||
index 08b5b56e069d038d72c87355920c4ce8a55ed805..555ffd4772d9d4903491fdff9f3682852f8a52bd 100644
|
||||
--- a/browser/components/tabbrowser/content/tabbrowser.js
|
||||
+++ b/browser/components/tabbrowser/content/tabbrowser.js
|
||||
@@ -502,6 +502,7 @@
|
||||
@@ -511,6 +511,7 @@
|
||||
* @type {MozBrowser[]}
|
||||
*/
|
||||
get splitViewBrowsers() {
|
||||
@@ -10,7 +10,7 @@ index 43fb79a3060e20f671ae6ffc26350c7abf497702..146b1559b8430773bd4ec173a8f4fe88
|
||||
const browsers = [];
|
||||
if (this.#activeSplitView) {
|
||||
for (const tab of this.#activeSplitView.tabs) {
|
||||
@@ -575,15 +576,66 @@
|
||||
@@ -584,15 +585,66 @@
|
||||
return this.tabContainer.visibleTabs;
|
||||
}
|
||||
|
||||
@@ -79,7 +79,17 @@ index 43fb79a3060e20f671ae6ffc26350c7abf497702..146b1559b8430773bd4ec173a8f4fe88
|
||||
set selectedTab(val) {
|
||||
if (
|
||||
gSharedTabWarning.willShowSharedTabWarning(val) ||
|
||||
@@ -659,6 +711,10 @@
|
||||
@@ -601,6 +653,9 @@
|
||||
) {
|
||||
return;
|
||||
}
|
||||
+ if (gZenWorkspaces.onBeforeTabSelect(val)) {
|
||||
+ return;
|
||||
+ }
|
||||
// Update the tab
|
||||
this.tabbox.selectedTab = val;
|
||||
}
|
||||
@@ -668,6 +723,10 @@
|
||||
userContextId = parseInt(tabArgument.getAttribute("usercontextid"), 10);
|
||||
}
|
||||
|
||||
@@ -90,7 +100,7 @@ index 43fb79a3060e20f671ae6ffc26350c7abf497702..146b1559b8430773bd4ec173a8f4fe88
|
||||
if (tabArgument && tabArgument.linkedBrowser) {
|
||||
remoteType = tabArgument.linkedBrowser.remoteType;
|
||||
initialBrowsingContextGroupId =
|
||||
@@ -751,6 +807,8 @@
|
||||
@@ -760,6 +819,8 @@
|
||||
this.tabpanels.appendChild(panel);
|
||||
|
||||
let tab = this.tabs[0];
|
||||
@@ -99,7 +109,7 @@ index 43fb79a3060e20f671ae6ffc26350c7abf497702..146b1559b8430773bd4ec173a8f4fe88
|
||||
tab.linkedPanel = uniqueId;
|
||||
this._selectedTab = tab;
|
||||
this._selectedBrowser = browser;
|
||||
@@ -1121,13 +1179,18 @@
|
||||
@@ -1131,13 +1192,18 @@
|
||||
}
|
||||
|
||||
this.showTab(aTab);
|
||||
@@ -119,7 +129,7 @@ index 43fb79a3060e20f671ae6ffc26350c7abf497702..146b1559b8430773bd4ec173a8f4fe88
|
||||
|
||||
aTab.setAttribute("pinned", "true");
|
||||
this._updateTabBarForPinnedTabs();
|
||||
@@ -1140,11 +1203,19 @@
|
||||
@@ -1150,11 +1216,19 @@
|
||||
}
|
||||
|
||||
this.#handleTabMove(aTab, () => {
|
||||
@@ -140,7 +150,7 @@ index 43fb79a3060e20f671ae6ffc26350c7abf497702..146b1559b8430773bd4ec173a8f4fe88
|
||||
});
|
||||
|
||||
aTab.style.marginInlineStart = "";
|
||||
@@ -1321,6 +1392,9 @@
|
||||
@@ -1369,6 +1443,9 @@
|
||||
|
||||
let LOCAL_PROTOCOLS = ["chrome:", "about:", "resource:", "data:"];
|
||||
|
||||
@@ -150,7 +160,7 @@ index 43fb79a3060e20f671ae6ffc26350c7abf497702..146b1559b8430773bd4ec173a8f4fe88
|
||||
if (
|
||||
aIconURL &&
|
||||
!LOCAL_PROTOCOLS.some(protocol => aIconURL.startsWith(protocol))
|
||||
@@ -1330,6 +1404,9 @@
|
||||
@@ -1378,6 +1455,9 @@
|
||||
);
|
||||
return;
|
||||
}
|
||||
@@ -160,7 +170,7 @@ index 43fb79a3060e20f671ae6ffc26350c7abf497702..146b1559b8430773bd4ec173a8f4fe88
|
||||
|
||||
let browser = this.getBrowserForTab(aTab);
|
||||
browser.mIconURL = aIconURL;
|
||||
@@ -1652,7 +1729,6 @@
|
||||
@@ -1700,7 +1780,6 @@
|
||||
|
||||
// Preview mode should not reset the owner
|
||||
if (!this._previewMode && !oldTab.selected) {
|
||||
@@ -168,15 +178,15 @@ index 43fb79a3060e20f671ae6ffc26350c7abf497702..146b1559b8430773bd4ec173a8f4fe88
|
||||
}
|
||||
|
||||
let lastRelatedTab = this._lastRelatedTabMap.get(oldTab);
|
||||
@@ -1743,6 +1819,7 @@
|
||||
@@ -1791,6 +1870,7 @@
|
||||
if (!this._previewMode) {
|
||||
newTab.recordTimeFromUnloadToReload();
|
||||
newTab.updateLastAccessed();
|
||||
+ newTab.removeAttribute("unread");
|
||||
oldTab.updateLastAccessed();
|
||||
// if this is the foreground window, update the last-seen timestamps.
|
||||
if (this.ownerGlobal == BrowserWindowTracker.getTopWindow()) {
|
||||
@@ -1957,6 +2034,9 @@
|
||||
if (this.documentGlobal == BrowserWindowTracker.getTopWindow()) {
|
||||
@@ -2005,6 +2085,9 @@
|
||||
}
|
||||
|
||||
let activeEl = document.activeElement;
|
||||
@@ -186,7 +196,7 @@ index 43fb79a3060e20f671ae6ffc26350c7abf497702..146b1559b8430773bd4ec173a8f4fe88
|
||||
// If focus is on the old tab, move it to the new tab.
|
||||
if (activeEl == oldTab) {
|
||||
newTab.focus();
|
||||
@@ -1995,7 +2075,7 @@
|
||||
@@ -2043,7 +2126,7 @@
|
||||
// Focus the location bar if it was previously focused for that tab.
|
||||
// In full screen mode, only bother making the location bar visible
|
||||
// if the tab is a blank one.
|
||||
@@ -195,7 +205,7 @@ index 43fb79a3060e20f671ae6ffc26350c7abf497702..146b1559b8430773bd4ec173a8f4fe88
|
||||
let selectURL = () => {
|
||||
if (this._asyncTabSwitching) {
|
||||
// Set _awaitingSetURI flag to suppress popup notification
|
||||
@@ -2283,7 +2363,12 @@
|
||||
@@ -2331,7 +2414,12 @@
|
||||
return this._setTabLabel(aTab, aLabel);
|
||||
}
|
||||
|
||||
@@ -209,7 +219,7 @@ index 43fb79a3060e20f671ae6ffc26350c7abf497702..146b1559b8430773bd4ec173a8f4fe88
|
||||
if (!aLabel || (isURL && /^about:reader\?url=/.test(aLabel))) {
|
||||
return false;
|
||||
}
|
||||
@@ -2408,7 +2493,7 @@
|
||||
@@ -2457,7 +2545,7 @@
|
||||
newIndex = this.selectedTab._tPos + 1;
|
||||
}
|
||||
|
||||
@@ -218,7 +228,7 @@ index 43fb79a3060e20f671ae6ffc26350c7abf497702..146b1559b8430773bd4ec173a8f4fe88
|
||||
if (this.isTabGroupLabel(targetTab)) {
|
||||
throw new Error(
|
||||
"Replacing a tab group label with a tab is not supported"
|
||||
@@ -2685,6 +2770,7 @@
|
||||
@@ -2737,6 +2825,7 @@
|
||||
uriIsAboutBlank,
|
||||
userContextId,
|
||||
skipLoad,
|
||||
@@ -226,7 +236,7 @@ index 43fb79a3060e20f671ae6ffc26350c7abf497702..146b1559b8430773bd4ec173a8f4fe88
|
||||
} = {}) {
|
||||
let b = document.createXULElement("browser");
|
||||
// Use the JSM global to create the permanentKey, so that if the
|
||||
@@ -2758,8 +2844,7 @@
|
||||
@@ -2810,8 +2899,7 @@
|
||||
// we use a different attribute name for this?
|
||||
b.setAttribute("name", name);
|
||||
}
|
||||
@@ -236,7 +246,7 @@ index 43fb79a3060e20f671ae6ffc26350c7abf497702..146b1559b8430773bd4ec173a8f4fe88
|
||||
b.setAttribute("transparent", "true");
|
||||
}
|
||||
|
||||
@@ -2929,7 +3014,7 @@
|
||||
@@ -2981,7 +3069,7 @@
|
||||
|
||||
let panel = this.getPanel(browser);
|
||||
let uniqueId = this._generateUniquePanelID();
|
||||
@@ -245,7 +255,7 @@ index 43fb79a3060e20f671ae6ffc26350c7abf497702..146b1559b8430773bd4ec173a8f4fe88
|
||||
aTab.linkedPanel = uniqueId;
|
||||
|
||||
// Inject the <browser> into the DOM if necessary.
|
||||
@@ -2989,8 +3074,8 @@
|
||||
@@ -3041,8 +3129,8 @@
|
||||
// If we transitioned from one browser to two browsers, we need to set
|
||||
// hasSiblings=false on both the existing browser and the new browser.
|
||||
if (this.tabs.length == 2) {
|
||||
@@ -256,7 +266,7 @@ index 43fb79a3060e20f671ae6ffc26350c7abf497702..146b1559b8430773bd4ec173a8f4fe88
|
||||
} else {
|
||||
aTab.linkedBrowser.browsingContext.hasSiblings = this.tabs.length > 1;
|
||||
}
|
||||
@@ -3175,7 +3260,6 @@
|
||||
@@ -3227,7 +3315,6 @@
|
||||
this.selectedTab = this.addTrustedTab(BROWSER_NEW_TAB_URL, {
|
||||
tabIndex: tab._tPos + 1,
|
||||
userContextId: tab.userContextId,
|
||||
@@ -264,24 +274,33 @@ index 43fb79a3060e20f671ae6ffc26350c7abf497702..146b1559b8430773bd4ec173a8f4fe88
|
||||
focusUrlBar: true,
|
||||
});
|
||||
resolve(this.selectedBrowser);
|
||||
@@ -3285,6 +3369,9 @@
|
||||
@@ -3337,6 +3424,10 @@
|
||||
schemelessInput,
|
||||
hasValidUserGestureActivation = false,
|
||||
textDirectiveUserActivation = false,
|
||||
+ _forZenEmptyTab,
|
||||
+ essential,
|
||||
+ zenWorkspaceId,
|
||||
+ skipRoute = false,
|
||||
} = {}
|
||||
) {
|
||||
// all callers of addTab that pass a params object need to pass
|
||||
@@ -3295,10 +3382,17 @@
|
||||
@@ -3347,10 +3438,25 @@
|
||||
);
|
||||
}
|
||||
|
||||
+ const beforeRouteResult = window.gZenSpaceRoutingManager.onBeforeAddTab(uriString, { skipRoute, pinned, tabGroup, fromExternal }, window);
|
||||
+ if (beforeRouteResult.shouldEarlyExit) {
|
||||
+ return null;
|
||||
+ }
|
||||
+
|
||||
+ let hasZenDefaultUserContextId = false;
|
||||
+ let zenForcedWorkspaceId = undefined;
|
||||
+ if (typeof gZenWorkspaces !== "undefined" && !_forZenEmptyTab) {
|
||||
+ [userContextId, hasZenDefaultUserContextId, zenForcedWorkspaceId] = gZenWorkspaces.getContextIdIfNeeded(userContextId, fromExternal);
|
||||
+ if (beforeRouteResult.isRouteFound && typeof userContextId !== "undefined") {
|
||||
+ userContextId = beforeRouteResult.userContextId;
|
||||
+ hasZenDefaultUserContextId = true;
|
||||
+ } else if (typeof gZenWorkspaces !== "undefined" && !_forZenEmptyTab) {
|
||||
+ [userContextId, hasZenDefaultUserContextId, zenForcedWorkspaceId] = gZenWorkspaces.getContextIdIfNeeded(userContextId, fromExternal, triggeringPrincipal);
|
||||
+ }
|
||||
+
|
||||
if (!UserInteraction.running("browser.tabs.opening", window)) {
|
||||
@@ -292,7 +311,7 @@ index 43fb79a3060e20f671ae6ffc26350c7abf497702..146b1559b8430773bd4ec173a8f4fe88
|
||||
// If we're opening a foreground tab, set the owner by default.
|
||||
ownerTab ??= inBackground ? null : this.selectedTab;
|
||||
|
||||
@@ -3306,6 +3400,7 @@
|
||||
@@ -3358,6 +3464,7 @@
|
||||
if (this.selectedTab.owner) {
|
||||
this.selectedTab.owner = null;
|
||||
}
|
||||
@@ -300,7 +319,7 @@ index 43fb79a3060e20f671ae6ffc26350c7abf497702..146b1559b8430773bd4ec173a8f4fe88
|
||||
|
||||
// Find the tab that opened this one, if any. This is used for
|
||||
// determining positioning, and inherited attributes such as the
|
||||
@@ -3358,6 +3453,22 @@
|
||||
@@ -3410,6 +3517,22 @@
|
||||
noInitialLabel,
|
||||
skipBackgroundNotify,
|
||||
});
|
||||
@@ -323,7 +342,7 @@ index 43fb79a3060e20f671ae6ffc26350c7abf497702..146b1559b8430773bd4ec173a8f4fe88
|
||||
if (insertTab) {
|
||||
// Insert the tab into the tab container in the correct position.
|
||||
this.#insertTabAtIndex(t, {
|
||||
@@ -3366,6 +3477,7 @@
|
||||
@@ -3418,6 +3541,7 @@
|
||||
ownerTab,
|
||||
openerTab,
|
||||
pinned,
|
||||
@@ -331,7 +350,7 @@ index 43fb79a3060e20f671ae6ffc26350c7abf497702..146b1559b8430773bd4ec173a8f4fe88
|
||||
bulkOrderedOpen,
|
||||
tabGroup: tabGroup ?? openerTab?.group,
|
||||
});
|
||||
@@ -3384,6 +3496,7 @@
|
||||
@@ -3436,6 +3560,7 @@
|
||||
openWindowInfo,
|
||||
skipLoad,
|
||||
triggeringRemoteType,
|
||||
@@ -339,7 +358,7 @@ index 43fb79a3060e20f671ae6ffc26350c7abf497702..146b1559b8430773bd4ec173a8f4fe88
|
||||
}));
|
||||
|
||||
if (focusUrlBar) {
|
||||
@@ -3508,6 +3621,12 @@
|
||||
@@ -3560,6 +3685,12 @@
|
||||
}
|
||||
}
|
||||
|
||||
@@ -347,12 +366,28 @@ index 43fb79a3060e20f671ae6ffc26350c7abf497702..146b1559b8430773bd4ec173a8f4fe88
|
||||
+ gZenVerticalTabsManager.animateItemOpen(t);
|
||||
+ }
|
||||
+ if (typeof window.gZenCompactModeManager !== "undefined" && !skipLoad && insertTab) {
|
||||
+ gZenCompactModeManager._onTabOpen(t, inBackground);
|
||||
+ gZenCompactModeManager._onTabOpen(t, inBackground, beforeRouteResult);
|
||||
+ }
|
||||
// Additionally send pinned tab events
|
||||
if (pinned) {
|
||||
this.#notifyPinnedStatus(t);
|
||||
@@ -3750,6 +3869,7 @@
|
||||
@@ -3570,6 +3701,15 @@
|
||||
if (!inBackground) {
|
||||
this.selectedTab = t;
|
||||
}
|
||||
+
|
||||
+ window.gZenSpaceRoutingManager.onAfterAddTab(
|
||||
+ uriString,
|
||||
+ t,
|
||||
+ { skipRoute: skipRoute || _forZenEmptyTab, fromExternal, pinned, tabGroup, inBackground },
|
||||
+ window,
|
||||
+ beforeRouteResult,
|
||||
+ );
|
||||
+
|
||||
return t;
|
||||
}
|
||||
|
||||
@@ -3802,6 +3942,7 @@
|
||||
isAdoptingGroup = false,
|
||||
isUserTriggered = false,
|
||||
telemetryUserCreateSource = "unknown",
|
||||
@@ -360,7 +395,7 @@ index 43fb79a3060e20f671ae6ffc26350c7abf497702..146b1559b8430773bd4ec173a8f4fe88
|
||||
} = {}
|
||||
) {
|
||||
if (
|
||||
@@ -3760,9 +3880,6 @@
|
||||
@@ -3812,9 +3953,6 @@
|
||||
!this.isSplitViewWrapper(tabOrSplitView)
|
||||
)
|
||||
) {
|
||||
@@ -370,7 +405,7 @@ index 43fb79a3060e20f671ae6ffc26350c7abf497702..146b1559b8430773bd4ec173a8f4fe88
|
||||
}
|
||||
|
||||
if (!color) {
|
||||
@@ -3783,9 +3900,14 @@
|
||||
@@ -3835,9 +3973,14 @@
|
||||
label,
|
||||
isAdoptingGroup
|
||||
);
|
||||
@@ -387,7 +422,7 @@ index 43fb79a3060e20f671ae6ffc26350c7abf497702..146b1559b8430773bd4ec173a8f4fe88
|
||||
);
|
||||
group.addTabs(tabsAndSplitViews);
|
||||
|
||||
@@ -3906,7 +4028,7 @@
|
||||
@@ -3958,7 +4101,7 @@
|
||||
}
|
||||
|
||||
this.#handleTabMove(tab, () =>
|
||||
@@ -396,7 +431,7 @@ index 43fb79a3060e20f671ae6ffc26350c7abf497702..146b1559b8430773bd4ec173a8f4fe88
|
||||
);
|
||||
}
|
||||
|
||||
@@ -3990,6 +4112,7 @@
|
||||
@@ -4044,6 +4187,7 @@
|
||||
color: group.color,
|
||||
insertBefore: newTabs[0],
|
||||
isAdoptingGroup: true,
|
||||
@@ -404,7 +439,7 @@ index 43fb79a3060e20f671ae6ffc26350c7abf497702..146b1559b8430773bd4ec173a8f4fe88
|
||||
});
|
||||
}
|
||||
|
||||
@@ -4200,6 +4323,7 @@
|
||||
@@ -4254,6 +4398,7 @@
|
||||
openWindowInfo,
|
||||
skipLoad,
|
||||
triggeringRemoteType,
|
||||
@@ -412,7 +447,7 @@ index 43fb79a3060e20f671ae6ffc26350c7abf497702..146b1559b8430773bd4ec173a8f4fe88
|
||||
}
|
||||
) {
|
||||
// If we don't have a preferred remote type (or it is `NOT_REMOTE`), and
|
||||
@@ -4269,6 +4393,7 @@
|
||||
@@ -4323,6 +4468,7 @@
|
||||
openWindowInfo,
|
||||
name,
|
||||
skipLoad,
|
||||
@@ -420,7 +455,7 @@ index 43fb79a3060e20f671ae6ffc26350c7abf497702..146b1559b8430773bd4ec173a8f4fe88
|
||||
});
|
||||
}
|
||||
|
||||
@@ -4482,9 +4607,9 @@
|
||||
@@ -4536,9 +4682,9 @@
|
||||
}
|
||||
|
||||
// Add a new tab if needed.
|
||||
@@ -432,7 +467,7 @@ index 43fb79a3060e20f671ae6ffc26350c7abf497702..146b1559b8430773bd4ec173a8f4fe88
|
||||
|
||||
let url = "about:blank";
|
||||
if (tabData.entries?.length) {
|
||||
@@ -4521,8 +4646,10 @@
|
||||
@@ -4575,8 +4721,10 @@
|
||||
insertTab: false,
|
||||
skipLoad: true,
|
||||
preferredRemoteType,
|
||||
@@ -444,7 +479,7 @@ index 43fb79a3060e20f671ae6ffc26350c7abf497702..146b1559b8430773bd4ec173a8f4fe88
|
||||
if (select) {
|
||||
tabToSelect = tab;
|
||||
}
|
||||
@@ -4544,7 +4671,8 @@
|
||||
@@ -4598,7 +4746,8 @@
|
||||
this.pinTab(tab);
|
||||
// Then ensure all the tab open/pinning information is sent.
|
||||
this._fireTabOpen(tab, {});
|
||||
@@ -454,7 +489,7 @@ index 43fb79a3060e20f671ae6ffc26350c7abf497702..146b1559b8430773bd4ec173a8f4fe88
|
||||
let { groupId } = tabData;
|
||||
const tabGroup = tabGroupWorkingData.get(groupId);
|
||||
// if a tab refers to a tab group we don't know, skip any group
|
||||
@@ -4564,7 +4692,10 @@
|
||||
@@ -4618,7 +4767,10 @@
|
||||
tabGroup.stateData.id,
|
||||
tabGroup.stateData.color,
|
||||
tabGroup.stateData.collapsed,
|
||||
@@ -466,7 +501,7 @@ index 43fb79a3060e20f671ae6ffc26350c7abf497702..146b1559b8430773bd4ec173a8f4fe88
|
||||
);
|
||||
tabsFragment.appendChild(tabGroup.node);
|
||||
}
|
||||
@@ -4619,9 +4750,21 @@
|
||||
@@ -4673,9 +4825,21 @@
|
||||
// to remove the old selected tab.
|
||||
if (tabToSelect) {
|
||||
let leftoverTab = this.selectedTab;
|
||||
@@ -488,7 +523,7 @@ index 43fb79a3060e20f671ae6ffc26350c7abf497702..146b1559b8430773bd4ec173a8f4fe88
|
||||
|
||||
if (tabs.length > 1 || !tabs[0].selected) {
|
||||
this._updateTabsAfterInsert();
|
||||
@@ -4812,11 +4955,14 @@
|
||||
@@ -4866,11 +5030,14 @@
|
||||
if (ownerTab) {
|
||||
tab.owner = ownerTab;
|
||||
}
|
||||
@@ -504,7 +539,7 @@ index 43fb79a3060e20f671ae6ffc26350c7abf497702..146b1559b8430773bd4ec173a8f4fe88
|
||||
if (
|
||||
!bulkOrderedOpen &&
|
||||
((openerTab &&
|
||||
@@ -4828,7 +4974,7 @@
|
||||
@@ -4882,7 +5049,7 @@
|
||||
let lastRelatedTab =
|
||||
openerTab && this._lastRelatedTabMap.get(openerTab);
|
||||
let previousTab = lastRelatedTab || openerTab || this.selectedTab;
|
||||
@@ -513,7 +548,7 @@ index 43fb79a3060e20f671ae6ffc26350c7abf497702..146b1559b8430773bd4ec173a8f4fe88
|
||||
tabGroup = previousTab.group;
|
||||
}
|
||||
if (
|
||||
@@ -4844,7 +4990,7 @@
|
||||
@@ -4898,7 +5065,7 @@
|
||||
previousTab.splitview
|
||||
) + 1;
|
||||
} else if (previousTab.visible) {
|
||||
@@ -522,7 +557,7 @@ index 43fb79a3060e20f671ae6ffc26350c7abf497702..146b1559b8430773bd4ec173a8f4fe88
|
||||
} else if (previousTab == FirefoxViewHandler.tab) {
|
||||
elementIndex = 0;
|
||||
}
|
||||
@@ -4872,14 +5018,14 @@
|
||||
@@ -4926,14 +5093,14 @@
|
||||
}
|
||||
// Ensure index is within bounds.
|
||||
if (tab.pinned) {
|
||||
@@ -541,7 +576,7 @@ index 43fb79a3060e20f671ae6ffc26350c7abf497702..146b1559b8430773bd4ec173a8f4fe88
|
||||
|
||||
if (pinned && !itemAfter?.pinned) {
|
||||
itemAfter = null;
|
||||
@@ -4896,7 +5042,7 @@
|
||||
@@ -4950,7 +5117,7 @@
|
||||
|
||||
this.tabContainer._invalidateCachedTabs();
|
||||
|
||||
@@ -550,7 +585,7 @@ index 43fb79a3060e20f671ae6ffc26350c7abf497702..146b1559b8430773bd4ec173a8f4fe88
|
||||
if (
|
||||
(this.isTab(itemAfter) && itemAfter.group == tabGroup) ||
|
||||
this.isSplitViewWrapper(itemAfter)
|
||||
@@ -4927,7 +5073,11 @@
|
||||
@@ -4981,7 +5148,11 @@
|
||||
const tabContainer = pinned
|
||||
? this.tabContainer.pinnedTabsContainer
|
||||
: this.tabContainer;
|
||||
@@ -562,7 +597,7 @@ index 43fb79a3060e20f671ae6ffc26350c7abf497702..146b1559b8430773bd4ec173a8f4fe88
|
||||
}
|
||||
|
||||
if (tab.group?.collapsed) {
|
||||
@@ -4942,6 +5092,7 @@
|
||||
@@ -4996,6 +5167,7 @@
|
||||
if (pinned) {
|
||||
this._updateTabBarForPinnedTabs();
|
||||
}
|
||||
@@ -570,7 +605,7 @@ index 43fb79a3060e20f671ae6ffc26350c7abf497702..146b1559b8430773bd4ec173a8f4fe88
|
||||
|
||||
TabBarVisibility.update();
|
||||
}
|
||||
@@ -5490,6 +5641,7 @@
|
||||
@@ -5544,6 +5716,7 @@
|
||||
telemetrySource,
|
||||
} = {}
|
||||
) {
|
||||
@@ -578,7 +613,7 @@ index 43fb79a3060e20f671ae6ffc26350c7abf497702..146b1559b8430773bd4ec173a8f4fe88
|
||||
// When 'closeWindowWithLastTab' pref is enabled, closing all tabs
|
||||
// can be considered equivalent to closing the window.
|
||||
if (
|
||||
@@ -5579,6 +5731,7 @@
|
||||
@@ -5633,6 +5806,7 @@
|
||||
if (lastToClose) {
|
||||
this.removeTab(lastToClose, aParams);
|
||||
}
|
||||
@@ -586,7 +621,7 @@ index 43fb79a3060e20f671ae6ffc26350c7abf497702..146b1559b8430773bd4ec173a8f4fe88
|
||||
} catch (e) {
|
||||
console.error(e);
|
||||
}
|
||||
@@ -5624,6 +5777,14 @@
|
||||
@@ -5678,6 +5852,14 @@
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -601,7 +636,7 @@ index 43fb79a3060e20f671ae6ffc26350c7abf497702..146b1559b8430773bd4ec173a8f4fe88
|
||||
let isVisibleTab = aTab.visible;
|
||||
// We have to sample the tab width now, since _beginRemoveTab might
|
||||
// end up modifying the DOM in such a way that aTab gets a new
|
||||
@@ -5631,6 +5792,9 @@
|
||||
@@ -5685,6 +5867,9 @@
|
||||
// state).
|
||||
let tabWidth = window.windowUtils.getBoundsWithoutFlushing(aTab).width;
|
||||
let isLastTab = this.#isLastTabInWindow(aTab);
|
||||
@@ -611,7 +646,7 @@ index 43fb79a3060e20f671ae6ffc26350c7abf497702..146b1559b8430773bd4ec173a8f4fe88
|
||||
if (
|
||||
!this._beginRemoveTab(aTab, {
|
||||
closeWindowFastpath: true,
|
||||
@@ -5642,13 +5806,14 @@
|
||||
@@ -5696,13 +5881,14 @@
|
||||
telemetrySource,
|
||||
})
|
||||
) {
|
||||
@@ -627,7 +662,7 @@ index 43fb79a3060e20f671ae6ffc26350c7abf497702..146b1559b8430773bd4ec173a8f4fe88
|
||||
let lockTabSizing =
|
||||
!this.tabContainer.verticalMode &&
|
||||
!aTab.pinned &&
|
||||
@@ -5679,7 +5844,13 @@
|
||||
@@ -5733,7 +5919,13 @@
|
||||
// We're not animating, so we can cancel the animation stopwatch.
|
||||
Glean.browserTabclose.timeAnim.cancel(aTab._closeTimeAnimTimerId);
|
||||
aTab._closeTimeAnimTimerId = null;
|
||||
@@ -642,7 +677,7 @@ index 43fb79a3060e20f671ae6ffc26350c7abf497702..146b1559b8430773bd4ec173a8f4fe88
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -5813,7 +5984,7 @@
|
||||
@@ -5867,7 +6059,7 @@
|
||||
closeWindowWithLastTab != null
|
||||
? closeWindowWithLastTab
|
||||
: !window.toolbar.visible ||
|
||||
@@ -651,7 +686,7 @@ index 43fb79a3060e20f671ae6ffc26350c7abf497702..146b1559b8430773bd4ec173a8f4fe88
|
||||
|
||||
if (closeWindow) {
|
||||
// We've already called beforeunload on all the relevant tabs if we get here,
|
||||
@@ -5837,6 +6008,7 @@
|
||||
@@ -5891,6 +6083,7 @@
|
||||
|
||||
newTab = true;
|
||||
}
|
||||
@@ -659,7 +694,7 @@ index 43fb79a3060e20f671ae6ffc26350c7abf497702..146b1559b8430773bd4ec173a8f4fe88
|
||||
aTab._endRemoveArgs = [closeWindow, newTab];
|
||||
|
||||
// swapBrowsersAndCloseOther will take care of closing the window without animation.
|
||||
@@ -5877,13 +6049,7 @@
|
||||
@@ -5931,13 +6124,7 @@
|
||||
aTab._mouseleave();
|
||||
|
||||
if (newTab) {
|
||||
@@ -674,7 +709,7 @@ index 43fb79a3060e20f671ae6ffc26350c7abf497702..146b1559b8430773bd4ec173a8f4fe88
|
||||
} else {
|
||||
TabBarVisibility.update();
|
||||
}
|
||||
@@ -6016,6 +6182,7 @@
|
||||
@@ -6070,6 +6257,7 @@
|
||||
this.tabs[i]._tPos = i;
|
||||
}
|
||||
|
||||
@@ -682,7 +717,7 @@ index 43fb79a3060e20f671ae6ffc26350c7abf497702..146b1559b8430773bd4ec173a8f4fe88
|
||||
if (!this._windowIsClosing) {
|
||||
// update tab close buttons state
|
||||
this.tabContainer._updateCloseButtons();
|
||||
@@ -6201,6 +6368,7 @@
|
||||
@@ -6255,6 +6443,7 @@
|
||||
memory_after: await getTotalMemoryUsage(),
|
||||
time_to_unload_in_ms: timeElapsed,
|
||||
});
|
||||
@@ -690,7 +725,7 @@ index 43fb79a3060e20f671ae6ffc26350c7abf497702..146b1559b8430773bd4ec173a8f4fe88
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -6246,6 +6414,7 @@
|
||||
@@ -6300,6 +6489,7 @@
|
||||
}
|
||||
|
||||
let excludeTabs = new Set(aExcludeTabs);
|
||||
@@ -698,7 +733,7 @@ index 43fb79a3060e20f671ae6ffc26350c7abf497702..146b1559b8430773bd4ec173a8f4fe88
|
||||
|
||||
// If this tab has a successor, it should be selectable, since
|
||||
// hiding or closing a tab removes that tab as a successor.
|
||||
@@ -6258,15 +6427,22 @@
|
||||
@@ -6312,15 +6502,22 @@
|
||||
!excludeTabs.has(aTab.owner) &&
|
||||
Services.prefs.getBoolPref("browser.tabs.selectOwnerOnClose")
|
||||
) {
|
||||
@@ -723,7 +758,7 @@ index 43fb79a3060e20f671ae6ffc26350c7abf497702..146b1559b8430773bd4ec173a8f4fe88
|
||||
let tab = this.tabContainer.findNextTab(aTab, {
|
||||
direction: 1,
|
||||
filter: _tab => remainingTabs.includes(_tab),
|
||||
@@ -6280,7 +6456,7 @@
|
||||
@@ -6334,7 +6531,7 @@
|
||||
}
|
||||
|
||||
if (tab) {
|
||||
@@ -732,7 +767,7 @@ index 43fb79a3060e20f671ae6ffc26350c7abf497702..146b1559b8430773bd4ec173a8f4fe88
|
||||
}
|
||||
|
||||
// If no qualifying visible tab was found, see if there is a tab in
|
||||
@@ -6301,7 +6477,7 @@
|
||||
@@ -6355,7 +6552,7 @@
|
||||
});
|
||||
}
|
||||
|
||||
@@ -741,7 +776,7 @@ index 43fb79a3060e20f671ae6ffc26350c7abf497702..146b1559b8430773bd4ec173a8f4fe88
|
||||
}
|
||||
|
||||
_blurTab(aTab) {
|
||||
@@ -6312,7 +6488,7 @@
|
||||
@@ -6366,7 +6563,7 @@
|
||||
* @returns {boolean}
|
||||
* False if swapping isn't permitted, true otherwise.
|
||||
*/
|
||||
@@ -750,7 +785,7 @@ index 43fb79a3060e20f671ae6ffc26350c7abf497702..146b1559b8430773bd4ec173a8f4fe88
|
||||
// Do not allow transfering a private tab to a non-private window
|
||||
// and vice versa.
|
||||
if (
|
||||
@@ -6366,6 +6542,7 @@
|
||||
@@ -6420,6 +6617,7 @@
|
||||
// fire the beforeunload event in the process. Close the other
|
||||
// window if this was its last tab.
|
||||
if (
|
||||
@@ -758,22 +793,22 @@ index 43fb79a3060e20f671ae6ffc26350c7abf497702..146b1559b8430773bd4ec173a8f4fe88
|
||||
!remoteBrowser._beginRemoveTab(aOtherTab, {
|
||||
adoptedByTab: aOurTab,
|
||||
closeWindowWithLastTab: true,
|
||||
@@ -6377,7 +6554,7 @@
|
||||
@@ -6431,7 +6629,7 @@
|
||||
// If this is the last tab of the window, hide the window
|
||||
// immediately without animation before the docshell swap, to avoid
|
||||
// about:blank being painted.
|
||||
- let [closeWindow] = aOtherTab._endRemoveArgs;
|
||||
+ let [closeWindow] = !zenCloseOther ? [false] : aOtherTab._endRemoveArgs;
|
||||
if (closeWindow) {
|
||||
let win = aOtherTab.ownerGlobal;
|
||||
let win = aOtherTab.documentGlobal;
|
||||
win.windowUtils.suppressAnimation(true);
|
||||
@@ -6511,11 +6688,13 @@
|
||||
@@ -6565,11 +6763,13 @@
|
||||
}
|
||||
|
||||
// Finish tearing down the tab that's going away.
|
||||
+ if (zenCloseOther) {
|
||||
if (closeWindow) {
|
||||
aOtherTab.ownerGlobal.close();
|
||||
aOtherTab.documentGlobal.close();
|
||||
} else {
|
||||
remoteBrowser._endRemoveTab(aOtherTab);
|
||||
}
|
||||
@@ -781,7 +816,7 @@ index 43fb79a3060e20f671ae6ffc26350c7abf497702..146b1559b8430773bd4ec173a8f4fe88
|
||||
|
||||
this.setTabTitle(aOurTab);
|
||||
|
||||
@@ -6717,10 +6896,10 @@
|
||||
@@ -6771,10 +6971,10 @@
|
||||
SessionStore.deleteCustomTabValue(aTab, "hiddenBy");
|
||||
}
|
||||
|
||||
@@ -794,7 +829,7 @@ index 43fb79a3060e20f671ae6ffc26350c7abf497702..146b1559b8430773bd4ec173a8f4fe88
|
||||
aTab.selected ||
|
||||
aTab.closing ||
|
||||
// Tabs that are sharing the screen, microphone or camera cannot be hidden.
|
||||
@@ -6780,7 +6959,8 @@
|
||||
@@ -6834,7 +7034,8 @@
|
||||
* @param {object} [aOptions={}]
|
||||
* Key-value pairs that will be serialized into the features string.
|
||||
*/
|
||||
@@ -804,7 +839,7 @@ index 43fb79a3060e20f671ae6ffc26350c7abf497702..146b1559b8430773bd4ec173a8f4fe88
|
||||
if (this.tabs.length == 1) {
|
||||
return null;
|
||||
}
|
||||
@@ -6797,7 +6977,7 @@
|
||||
@@ -6851,7 +7052,7 @@
|
||||
// tell a new window to take the "dropped" tab
|
||||
let args = Cc["@mozilla.org/array;1"].createInstance(Ci.nsIMutableArray);
|
||||
args.appendElement(aTab.splitview ?? aTab);
|
||||
@@ -813,7 +848,7 @@ index 43fb79a3060e20f671ae6ffc26350c7abf497702..146b1559b8430773bd4ec173a8f4fe88
|
||||
private: PrivateBrowsingUtils.isWindowPrivate(window),
|
||||
features: Object.entries(aOptions)
|
||||
.map(([key, value]) => `${key}=${value}`)
|
||||
@@ -6805,6 +6985,8 @@
|
||||
@@ -6859,6 +7060,8 @@
|
||||
openerWindow: window,
|
||||
args,
|
||||
});
|
||||
@@ -822,7 +857,7 @@ index 43fb79a3060e20f671ae6ffc26350c7abf497702..146b1559b8430773bd4ec173a8f4fe88
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -6917,7 +7099,7 @@
|
||||
@@ -6971,7 +7174,7 @@
|
||||
* `true` if element is a `<tab-group>`
|
||||
*/
|
||||
isTabGroup(element) {
|
||||
@@ -831,7 +866,7 @@ index 43fb79a3060e20f671ae6ffc26350c7abf497702..146b1559b8430773bd4ec173a8f4fe88
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -7002,8 +7184,8 @@
|
||||
@@ -7056,8 +7259,8 @@
|
||||
}
|
||||
|
||||
// Don't allow mixing pinned and unpinned tabs.
|
||||
@@ -842,7 +877,7 @@ index 43fb79a3060e20f671ae6ffc26350c7abf497702..146b1559b8430773bd4ec173a8f4fe88
|
||||
} else {
|
||||
tabIndex = Math.max(tabIndex, this.pinnedTabCount);
|
||||
}
|
||||
@@ -7049,8 +7231,8 @@
|
||||
@@ -7103,8 +7306,8 @@
|
||||
this.#handleTabMove(
|
||||
element,
|
||||
() => {
|
||||
@@ -853,7 +888,7 @@ index 43fb79a3060e20f671ae6ffc26350c7abf497702..146b1559b8430773bd4ec173a8f4fe88
|
||||
neighbor = neighbor.group;
|
||||
}
|
||||
if (neighbor?.splitview) {
|
||||
@@ -7061,6 +7243,12 @@
|
||||
@@ -7115,6 +7318,12 @@
|
||||
return;
|
||||
}
|
||||
}
|
||||
@@ -866,7 +901,7 @@ index 43fb79a3060e20f671ae6ffc26350c7abf497702..146b1559b8430773bd4ec173a8f4fe88
|
||||
|
||||
if (movingForwards && neighbor) {
|
||||
neighbor.after(element);
|
||||
@@ -7119,23 +7307,31 @@
|
||||
@@ -7173,23 +7382,31 @@
|
||||
#moveTabNextTo(element, targetElement, moveBefore = false, metricsContext) {
|
||||
if (this.isTabGroupLabel(targetElement)) {
|
||||
targetElement = targetElement.group;
|
||||
@@ -904,7 +939,7 @@ index 43fb79a3060e20f671ae6ffc26350c7abf497702..146b1559b8430773bd4ec173a8f4fe88
|
||||
} else if (!element.pinned && targetElement && targetElement.pinned) {
|
||||
// If the caller asks to move an unpinned element next to a pinned
|
||||
// tab, move the unpinned element to be the first unpinned element
|
||||
@@ -7148,12 +7344,35 @@
|
||||
@@ -7202,12 +7419,35 @@
|
||||
// move the tab group right before the first unpinned tab.
|
||||
// 4. Moving a tab group and the first unpinned tab is grouped:
|
||||
// move the tab group right before the first unpinned tab's tab group.
|
||||
@@ -941,7 +976,7 @@ index 43fb79a3060e20f671ae6ffc26350c7abf497702..146b1559b8430773bd4ec173a8f4fe88
|
||||
|
||||
// We want to include the splitview wrapper if it's the targetElement, but
|
||||
// not in the case where we want to reverse tabs within the same splitview.
|
||||
@@ -7162,6 +7381,7 @@
|
||||
@@ -7216,6 +7456,7 @@
|
||||
}
|
||||
|
||||
let getContainer = () =>
|
||||
@@ -949,7 +984,7 @@ index 43fb79a3060e20f671ae6ffc26350c7abf497702..146b1559b8430773bd4ec173a8f4fe88
|
||||
element.pinned
|
||||
? this.tabContainer.pinnedTabsContainer
|
||||
: this.tabContainer;
|
||||
@@ -7170,11 +7390,15 @@
|
||||
@@ -7224,11 +7465,15 @@
|
||||
element,
|
||||
() => {
|
||||
if (moveBefore) {
|
||||
@@ -966,7 +1001,7 @@ index 43fb79a3060e20f671ae6ffc26350c7abf497702..146b1559b8430773bd4ec173a8f4fe88
|
||||
}
|
||||
},
|
||||
metricsContext
|
||||
@@ -7248,11 +7472,15 @@
|
||||
@@ -7302,11 +7547,15 @@
|
||||
* @param {TabMetricsContext} [metricsContext]
|
||||
*/
|
||||
moveTabToExistingGroup(aTab, aGroup, metricsContext) {
|
||||
@@ -985,7 +1020,7 @@ index 43fb79a3060e20f671ae6ffc26350c7abf497702..146b1559b8430773bd4ec173a8f4fe88
|
||||
}
|
||||
if (aTab.group && aTab.group.id === aGroup.id) {
|
||||
return;
|
||||
@@ -7324,6 +7552,7 @@
|
||||
@@ -7378,6 +7627,7 @@
|
||||
|
||||
let state = {
|
||||
tabIndex: tab._tPos,
|
||||
@@ -993,7 +1028,7 @@ index 43fb79a3060e20f671ae6ffc26350c7abf497702..146b1559b8430773bd4ec173a8f4fe88
|
||||
};
|
||||
if (tab.visible) {
|
||||
state.elementIndex = tab.elementIndex;
|
||||
@@ -7355,7 +7584,7 @@
|
||||
@@ -7409,7 +7659,7 @@
|
||||
let changedSplitView =
|
||||
previousTabState.splitViewId != currentTabState.splitViewId;
|
||||
|
||||
@@ -1002,7 +1037,7 @@ index 43fb79a3060e20f671ae6ffc26350c7abf497702..146b1559b8430773bd4ec173a8f4fe88
|
||||
tab.dispatchEvent(
|
||||
new CustomEvent("TabMove", {
|
||||
bubbles: true,
|
||||
@@ -7402,6 +7631,10 @@
|
||||
@@ -7456,6 +7706,10 @@
|
||||
|
||||
moveActionCallback();
|
||||
|
||||
@@ -1013,13 +1048,13 @@ index 43fb79a3060e20f671ae6ffc26350c7abf497702..146b1559b8430773bd4ec173a8f4fe88
|
||||
// Clear tabs cache after moving nodes because the order of tabs may have
|
||||
// changed.
|
||||
this.tabContainer._invalidateCachedTabs();
|
||||
@@ -7452,7 +7685,22 @@
|
||||
@@ -7506,7 +7760,22 @@
|
||||
* @returns {object}
|
||||
* The new tab in the current window, null if the tab couldn't be adopted.
|
||||
*/
|
||||
- adoptTab(aTab, { elementIndex, tabIndex, selectTab = false } = {}) {
|
||||
+ adoptTab(aTab, { elementIndex, tabIndex, selectTab = false, spaceId = null } = {}) {
|
||||
+ if (window.gZenWorkspaces.currentWindowIsSyncing && aTab.ownerGlobal.gZenWorkspaces?.currentWindowIsSyncing) {
|
||||
+ if (window.gZenWorkspaces.currentWindowIsSyncing && aTab.documentGlobal.gZenWorkspaces?.currentWindowIsSyncing) {
|
||||
+ const tabId = aTab.id;
|
||||
+ const thisTab = window.gZenWindowSync.getItemFromWindow(window, tabId);
|
||||
+ if (thisTab) {
|
||||
@@ -1037,7 +1072,7 @@ index 43fb79a3060e20f671ae6ffc26350c7abf497702..146b1559b8430773bd4ec173a8f4fe88
|
||||
// Swap the dropped tab with a new one we create and then close
|
||||
// it in the other window (making it seem to have moved between
|
||||
// windows). We also ensure that the tab we create to swap into has
|
||||
@@ -7495,6 +7743,8 @@
|
||||
@@ -7549,6 +7818,8 @@
|
||||
}
|
||||
params.skipLoad = true;
|
||||
let newTab = this.addWebTab("about:blank", params);
|
||||
@@ -1046,7 +1081,7 @@ index 43fb79a3060e20f671ae6ffc26350c7abf497702..146b1559b8430773bd4ec173a8f4fe88
|
||||
|
||||
aTab.container.tabDragAndDrop.finishAnimateTabMove();
|
||||
|
||||
@@ -8205,7 +8455,7 @@
|
||||
@@ -8259,7 +8530,7 @@
|
||||
// preventDefault(). It will still raise the window if appropriate.
|
||||
return;
|
||||
}
|
||||
@@ -1055,7 +1090,7 @@ index 43fb79a3060e20f671ae6ffc26350c7abf497702..146b1559b8430773bd4ec173a8f4fe88
|
||||
window.focus();
|
||||
aEvent.preventDefault();
|
||||
}
|
||||
@@ -8222,7 +8472,6 @@
|
||||
@@ -8276,7 +8547,6 @@
|
||||
|
||||
on_TabGroupCollapse(aEvent) {
|
||||
aEvent.target.tabs.forEach(tab => {
|
||||
@@ -1063,7 +1098,7 @@ index 43fb79a3060e20f671ae6ffc26350c7abf497702..146b1559b8430773bd4ec173a8f4fe88
|
||||
});
|
||||
}
|
||||
|
||||
@@ -8556,7 +8805,9 @@
|
||||
@@ -8630,7 +8900,9 @@
|
||||
|
||||
let filter = this._tabFilters.get(tab);
|
||||
if (filter) {
|
||||
@@ -1073,7 +1108,7 @@ index 43fb79a3060e20f671ae6ffc26350c7abf497702..146b1559b8430773bd4ec173a8f4fe88
|
||||
|
||||
let listener = this._tabListeners.get(tab);
|
||||
if (listener) {
|
||||
@@ -9359,6 +9610,7 @@
|
||||
@@ -9435,6 +9707,7 @@
|
||||
aWebProgress.isTopLevel
|
||||
) {
|
||||
this.mTab.setAttribute("busy", "true");
|
||||
@@ -1081,7 +1116,7 @@ index 43fb79a3060e20f671ae6ffc26350c7abf497702..146b1559b8430773bd4ec173a8f4fe88
|
||||
gBrowser._tabAttrModified(this.mTab, ["busy"]);
|
||||
this.mTab._notselectedsinceload = !this.mTab.selected;
|
||||
}
|
||||
@@ -9439,6 +9691,7 @@
|
||||
@@ -9515,6 +9788,7 @@
|
||||
// known defaults. Note we use the original URL since about:newtab
|
||||
// redirects to a prerendered page.
|
||||
const shouldRemoveFavicon =
|
||||
@@ -1089,7 +1124,7 @@ index 43fb79a3060e20f671ae6ffc26350c7abf497702..146b1559b8430773bd4ec173a8f4fe88
|
||||
!this.mBrowser.mIconURL &&
|
||||
!ignoreBlank &&
|
||||
!(originalLocation.spec in FAVICON_DEFAULTS);
|
||||
@@ -9613,13 +9866,6 @@
|
||||
@@ -9689,13 +9963,6 @@
|
||||
this.mBrowser.originalURI = aRequest.originalURI;
|
||||
}
|
||||
|
||||
@@ -1103,7 +1138,7 @@ index 43fb79a3060e20f671ae6ffc26350c7abf497702..146b1559b8430773bd4ec173a8f4fe88
|
||||
}
|
||||
|
||||
let userContextId = this.mBrowser.getAttribute("usercontextid") || 0;
|
||||
@@ -10507,7 +10753,8 @@ var TabContextMenu = {
|
||||
@@ -10587,7 +10854,8 @@ var TabContextMenu = {
|
||||
);
|
||||
contextUnpinSelectedTabs.hidden =
|
||||
!this.contextTab.pinned || !this.multiselected;
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
diff --git a/browser/components/tabbrowser/content/tabgroup.js b/browser/components/tabbrowser/content/tabgroup.js
|
||||
index d1be14df27d76a191eaff05502c030fd68c46738..e9b5e90e39b594a6119081c8d707fb4a064fea9b 100644
|
||||
index e78fa0dec83424c0059c081f83fda0d23bdb5a94..a7de584d9029ff9e55d809d50377593e398ee999 100644
|
||||
--- a/browser/components/tabbrowser/content/tabgroup.js
|
||||
+++ b/browser/components/tabbrowser/content/tabgroup.js
|
||||
@@ -14,11 +14,11 @@
|
||||
@@ -49,7 +49,7 @@ index d1be14df27d76a191eaff05502c030fd68c46738..e9b5e90e39b594a6119081c8d707fb4a
|
||||
|
||||
// Similar to above, always set up TabSelect listener, as this gets
|
||||
// removed in disconnectedCallback
|
||||
this.ownerGlobal.addEventListener("TabSelect", this);
|
||||
this.documentGlobal.addEventListener("TabSelect", this);
|
||||
this.addEventListener("SplitViewTabChange", this);
|
||||
|
||||
- if (this._initialized) {
|
||||
@@ -129,7 +129,7 @@ index d1be14df27d76a191eaff05502c030fd68c46738..e9b5e90e39b594a6119081c8d707fb4a
|
||||
}
|
||||
|
||||
get color() {
|
||||
@@ -317,6 +348,9 @@
|
||||
@@ -335,6 +366,9 @@
|
||||
}
|
||||
|
||||
set collapsed(val) {
|
||||
@@ -139,7 +139,7 @@ index d1be14df27d76a191eaff05502c030fd68c46738..e9b5e90e39b594a6119081c8d707fb4a
|
||||
if (!!val == this.collapsed) {
|
||||
return;
|
||||
}
|
||||
@@ -403,7 +437,6 @@
|
||||
@@ -421,7 +455,6 @@
|
||||
tabGroupName,
|
||||
})
|
||||
.then(result => {
|
||||
@@ -147,7 +147,7 @@ index d1be14df27d76a191eaff05502c030fd68c46738..e9b5e90e39b594a6119081c8d707fb4a
|
||||
});
|
||||
}
|
||||
|
||||
@@ -478,13 +511,68 @@
|
||||
@@ -496,13 +529,68 @@
|
||||
* @returns {MozTabbrowserTab[]}
|
||||
*/
|
||||
get tabs() {
|
||||
@@ -221,15 +221,15 @@ index d1be14df27d76a191eaff05502c030fd68c46738..e9b5e90e39b594a6119081c8d707fb4a
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -592,7 +680,6 @@
|
||||
@@ -610,7 +698,6 @@
|
||||
);
|
||||
} else {
|
||||
if (tabOrSplitView.pinned) {
|
||||
- tabOrSplitView.ownerGlobal.gBrowser.unpinTab(tabOrSplitView);
|
||||
- tabOrSplitView.documentGlobal.gBrowser.unpinTab(tabOrSplitView);
|
||||
}
|
||||
let tabToMove =
|
||||
this.ownerGlobal === tabOrSplitView.ownerGlobal
|
||||
@@ -661,7 +748,7 @@
|
||||
this.documentGlobal === tabOrSplitView.documentGlobal
|
||||
@@ -679,7 +766,7 @@
|
||||
*/
|
||||
on_click(event) {
|
||||
let isToggleElement =
|
||||
@@ -238,7 +238,7 @@ index d1be14df27d76a191eaff05502c030fd68c46738..e9b5e90e39b594a6119081c8d707fb4a
|
||||
event.target === this.#overflowCountLabel;
|
||||
if (isToggleElement && event.button === 0) {
|
||||
event.preventDefault();
|
||||
@@ -740,5 +827,6 @@
|
||||
@@ -758,5 +845,6 @@
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -1,8 +1,23 @@
|
||||
diff --git a/browser/components/tabbrowser/content/tabs.js b/browser/components/tabbrowser/content/tabs.js
|
||||
index a2db42fba8d1f1d9df1dc295adb64be3f5885d50..2dd43fe4898badeaf9bc669502ead2c56982d1aa 100644
|
||||
index 568f3a7cc7051ff8cb569f6bcb8018a5212f7072..b9a1cfe3a4a5035d9b06b0b3826a97c52cfcb39e 100644
|
||||
--- a/browser/components/tabbrowser/content/tabs.js
|
||||
+++ b/browser/components/tabbrowser/content/tabs.js
|
||||
@@ -230,7 +230,7 @@
|
||||
@@ -197,8 +197,12 @@
|
||||
XPCOMUtils.defineLazyPreferenceGetter(
|
||||
this,
|
||||
"_sidebarPositionStart",
|
||||
- "sidebar.position_start",
|
||||
- true
|
||||
+ "zen.tabs.vertical.right-side",
|
||||
+ true,
|
||||
+ null,
|
||||
+ newValue => {
|
||||
+ return !newValue;
|
||||
+ }
|
||||
);
|
||||
|
||||
if (gMultiProcessBrowser) {
|
||||
@@ -220,7 +224,7 @@
|
||||
|
||||
this.tooltip = "tabbrowser-tab-tooltip";
|
||||
|
||||
@@ -11,7 +26,7 @@ index a2db42fba8d1f1d9df1dc295adb64be3f5885d50..2dd43fe4898badeaf9bc669502ead2c5
|
||||
this.tabDragAndDrop.init();
|
||||
}
|
||||
|
||||
@@ -454,7 +454,7 @@
|
||||
@@ -444,7 +448,7 @@
|
||||
// and we're not hitting the scroll buttons.
|
||||
if (
|
||||
event.button != 0 ||
|
||||
@@ -20,7 +35,7 @@ index a2db42fba8d1f1d9df1dc295adb64be3f5885d50..2dd43fe4898badeaf9bc669502ead2c5
|
||||
event.composedTarget.localName == "toolbarbutton"
|
||||
) {
|
||||
return;
|
||||
@@ -535,7 +535,6 @@
|
||||
@@ -525,7 +529,6 @@
|
||||
});
|
||||
}
|
||||
} else if (isTabGroupLabel(event.target)) {
|
||||
@@ -28,7 +43,7 @@ index a2db42fba8d1f1d9df1dc295adb64be3f5885d50..2dd43fe4898badeaf9bc669502ead2c5
|
||||
} else if (
|
||||
event.originalTarget.closest("scrollbox") &&
|
||||
!Services.prefs.getBoolPref(
|
||||
@@ -571,6 +570,9 @@
|
||||
@@ -561,6 +564,9 @@
|
||||
}
|
||||
|
||||
on_keydown(event) {
|
||||
@@ -38,7 +53,7 @@ index a2db42fba8d1f1d9df1dc295adb64be3f5885d50..2dd43fe4898badeaf9bc669502ead2c5
|
||||
let { altKey, shiftKey } = event;
|
||||
let [accel, nonAccel] =
|
||||
AppConstants.platform == "macosx"
|
||||
@@ -765,7 +767,6 @@
|
||||
@@ -755,7 +761,6 @@
|
||||
this._updateCloseButtons();
|
||||
|
||||
if (!this.#animatingGroups.size) {
|
||||
@@ -46,7 +61,7 @@ index a2db42fba8d1f1d9df1dc295adb64be3f5885d50..2dd43fe4898badeaf9bc669502ead2c5
|
||||
}
|
||||
|
||||
document
|
||||
@@ -832,7 +833,7 @@
|
||||
@@ -822,7 +827,7 @@
|
||||
}
|
||||
|
||||
get newTabButton() {
|
||||
@@ -55,7 +70,7 @@ index a2db42fba8d1f1d9df1dc295adb64be3f5885d50..2dd43fe4898badeaf9bc669502ead2c5
|
||||
}
|
||||
|
||||
get verticalMode() {
|
||||
@@ -848,6 +849,7 @@
|
||||
@@ -838,6 +843,7 @@
|
||||
}
|
||||
|
||||
get overflowing() {
|
||||
@@ -63,7 +78,7 @@ index a2db42fba8d1f1d9df1dc295adb64be3f5885d50..2dd43fe4898badeaf9bc669502ead2c5
|
||||
return this.hasAttribute("overflow");
|
||||
}
|
||||
|
||||
@@ -861,29 +863,56 @@
|
||||
@@ -851,29 +857,56 @@
|
||||
if (pinnedChildren?.at(-1)?.id == "pinned-tabs-container-periphery") {
|
||||
pinnedChildren.pop();
|
||||
}
|
||||
@@ -93,7 +108,7 @@ index a2db42fba8d1f1d9df1dc295adb64be3f5885d50..2dd43fe4898badeaf9bc669502ead2c5
|
||||
+ } else if (!isTab(tab)) {
|
||||
+ tabs.splice(i, 1);
|
||||
+ }
|
||||
}
|
||||
+ }
|
||||
+ };
|
||||
+ expandTabs(pinnedTabs);
|
||||
+ expandTabs(unpinnedChildren);
|
||||
@@ -114,7 +129,7 @@ index a2db42fba8d1f1d9df1dc295adb64be3f5885d50..2dd43fe4898badeaf9bc669502ead2c5
|
||||
+ // remove the separator from the list
|
||||
+ allTabs.splice(i, 1);
|
||||
+ i--;
|
||||
+ }
|
||||
}
|
||||
+ i++;
|
||||
}
|
||||
-
|
||||
@@ -130,7 +145,7 @@ index a2db42fba8d1f1d9df1dc295adb64be3f5885d50..2dd43fe4898badeaf9bc669502ead2c5
|
||||
}
|
||||
|
||||
get allSplitViews() {
|
||||
@@ -968,29 +997,28 @@
|
||||
@@ -958,29 +991,28 @@
|
||||
return this.#focusableItems;
|
||||
}
|
||||
|
||||
@@ -170,7 +185,7 @@ index a2db42fba8d1f1d9df1dc295adb64be3f5885d50..2dd43fe4898badeaf9bc669502ead2c5
|
||||
this.#focusableItems = focusableItems;
|
||||
|
||||
return this.#focusableItems;
|
||||
@@ -1003,6 +1031,7 @@
|
||||
@@ -993,6 +1025,7 @@
|
||||
* focusable (ex, we don't want the splitview container to be focusable, only its children).
|
||||
*/
|
||||
get dragAndDropElements() {
|
||||
@@ -178,7 +193,7 @@ index a2db42fba8d1f1d9df1dc295adb64be3f5885d50..2dd43fe4898badeaf9bc669502ead2c5
|
||||
if (this.#dragAndDropElements) {
|
||||
return this.#dragAndDropElements;
|
||||
}
|
||||
@@ -1073,6 +1102,7 @@
|
||||
@@ -1063,6 +1096,7 @@
|
||||
_invalidateCachedTabs() {
|
||||
this.#allTabs = null;
|
||||
this._invalidateCachedVisibleTabs();
|
||||
@@ -186,7 +201,7 @@ index a2db42fba8d1f1d9df1dc295adb64be3f5885d50..2dd43fe4898badeaf9bc669502ead2c5
|
||||
}
|
||||
|
||||
_invalidateCachedVisibleTabs() {
|
||||
@@ -1092,7 +1122,8 @@
|
||||
@@ -1082,7 +1116,8 @@
|
||||
|
||||
isContainerVerticalPinnedGrid(tab) {
|
||||
return (
|
||||
@@ -196,7 +211,7 @@ index a2db42fba8d1f1d9df1dc295adb64be3f5885d50..2dd43fe4898badeaf9bc669502ead2c5
|
||||
this.verticalMode &&
|
||||
this.hasAttribute("expanded") &&
|
||||
!this.expandOnHover
|
||||
@@ -1186,7 +1217,7 @@
|
||||
@@ -1176,7 +1211,7 @@
|
||||
|
||||
if (node == null) {
|
||||
// We have a container for non-tab elements at the end of the scrollbox.
|
||||
@@ -205,7 +220,7 @@ index a2db42fba8d1f1d9df1dc295adb64be3f5885d50..2dd43fe4898badeaf9bc669502ead2c5
|
||||
}
|
||||
|
||||
node.before(tab);
|
||||
@@ -1281,7 +1312,7 @@
|
||||
@@ -1271,7 +1306,7 @@
|
||||
// There are separate "new tab" buttons for horizontal tabs toolbar, vertical tabs and
|
||||
// for when the tab strip is overflowed (which is shared by vertical and horizontal tabs);
|
||||
// Attach the long click popup to all of them.
|
||||
@@ -214,7 +229,7 @@ index a2db42fba8d1f1d9df1dc295adb64be3f5885d50..2dd43fe4898badeaf9bc669502ead2c5
|
||||
const newTab2 = this.newTabButton;
|
||||
const newTabVertical = document.getElementById(
|
||||
"vertical-tabs-newtab-button"
|
||||
@@ -1386,8 +1417,10 @@
|
||||
@@ -1376,8 +1411,10 @@
|
||||
*/
|
||||
_handleTabSelect(aInstant) {
|
||||
let selectedTab = this.selectedItem;
|
||||
@@ -225,7 +240,7 @@ index a2db42fba8d1f1d9df1dc295adb64be3f5885d50..2dd43fe4898badeaf9bc669502ead2c5
|
||||
selectedTab._notselectedsinceload = false;
|
||||
}
|
||||
|
||||
@@ -1396,7 +1429,7 @@
|
||||
@@ -1386,7 +1423,7 @@
|
||||
* @param {boolean} [shouldScrollInstantly=false]
|
||||
*/
|
||||
#ensureTabIsVisible(tab, shouldScrollInstantly = false) {
|
||||
@@ -234,7 +249,7 @@ index a2db42fba8d1f1d9df1dc295adb64be3f5885d50..2dd43fe4898badeaf9bc669502ead2c5
|
||||
if (arrowScrollbox?.overflowing) {
|
||||
arrowScrollbox.ensureElementIsVisible(tab, shouldScrollInstantly);
|
||||
}
|
||||
@@ -1523,7 +1556,7 @@
|
||||
@@ -1513,7 +1550,7 @@
|
||||
}
|
||||
|
||||
_notifyBackgroundTab(aTab) {
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
diff --git a/browser/components/urlbar/UrlbarController.sys.mjs b/browser/components/urlbar/UrlbarController.sys.mjs
|
||||
index bb0189fbfc91b3fc3b399b077a35f7b60a3f985f..c4dd60c6fb6d7eb2288a033708836f9983530e2c 100644
|
||||
index a05894d593e4149097c473822a38f87b2220625f..1660106c2a6548920fdffd2656e5a1f12c2d548b 100644
|
||||
--- a/browser/components/urlbar/UrlbarController.sys.mjs
|
||||
+++ b/browser/components/urlbar/UrlbarController.sys.mjs
|
||||
@@ -305,7 +305,6 @@ export class UrlbarController {
|
||||
@@ -10,7 +10,7 @@ index bb0189fbfc91b3fc3b399b077a35f7b60a3f985f..c4dd60c6fb6d7eb2288a033708836f99
|
||||
this.view.isOpen &&
|
||||
event.ctrlKey &&
|
||||
(event.key == "n" || event.key == "p")
|
||||
@@ -456,6 +455,8 @@ export class UrlbarController {
|
||||
@@ -494,6 +493,8 @@ export class UrlbarController {
|
||||
});
|
||||
}
|
||||
event.preventDefault();
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
diff --git a/browser/components/urlbar/UrlbarProvidersManager.sys.mjs b/browser/components/urlbar/UrlbarProvidersManager.sys.mjs
|
||||
index d9048a3b8b1f18745c01e40e12f529db3cfaa79e..1ba124a710fcf734ea11f7ccfd4f2f6ebe53e7d2 100644
|
||||
index 8de151f473ac6b95bc606251f78a4bede093ee0c..dbd302259c54b0196a370b9ff12ba0dcf1545272 100644
|
||||
--- a/browser/components/urlbar/UrlbarProvidersManager.sys.mjs
|
||||
+++ b/browser/components/urlbar/UrlbarProvidersManager.sys.mjs
|
||||
@@ -913,6 +913,7 @@ export class Query {
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
diff --git a/browser/components/urlbar/UrlbarUtils.sys.mjs b/browser/components/urlbar/UrlbarUtils.sys.mjs
|
||||
index 62367c5a77614e5973791abacd068b39e0f3ab34..c930943b5bfa8a2e6dee43f0ec7a10274a7c7638 100644
|
||||
index 2f03bdf632c6ca15c728df2801162da5159682da..6834daede8cb11854f137602100183d85a930686 100644
|
||||
--- a/browser/components/urlbar/UrlbarUtils.sys.mjs
|
||||
+++ b/browser/components/urlbar/UrlbarUtils.sys.mjs
|
||||
@@ -109,6 +109,8 @@ export var UrlbarUtils = {
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
diff --git a/browser/components/urlbar/UrlbarValueFormatter.sys.mjs b/browser/components/urlbar/UrlbarValueFormatter.sys.mjs
|
||||
index 344a9a5b969e679040a650dad311c7413f52bbbd..24111cef5e476253f4e69c4d99f6f220bfd8cd7e 100644
|
||||
index 8def83509f097ba034b9d94ae00d2ee474ec2d30..ebdb84b9af928b132b848bd4c5bb506d813e5e06 100644
|
||||
--- a/browser/components/urlbar/UrlbarValueFormatter.sys.mjs
|
||||
+++ b/browser/components/urlbar/UrlbarValueFormatter.sys.mjs
|
||||
@@ -77,7 +77,7 @@ export class UrlbarValueFormatter {
|
||||
@@ -30,7 +30,7 @@ index 344a9a5b969e679040a650dad311c7413f52bbbd..24111cef5e476253f4e69c4d99f6f220
|
||||
// Make sure the host is always visible. Since it is aligned on
|
||||
// the first strong directional character, we set scrollLeft
|
||||
// appropriately to ensure the domain stays visible in case of an
|
||||
@@ -371,7 +383,7 @@ export class UrlbarValueFormatter {
|
||||
@@ -381,7 +393,7 @@ export class UrlbarValueFormatter {
|
||||
* @returns {boolean}
|
||||
* True if formatting was applied and false if not.
|
||||
*/
|
||||
@@ -39,7 +39,7 @@ index 344a9a5b969e679040a650dad311c7413f52bbbd..24111cef5e476253f4e69c4d99f6f220
|
||||
let urlMetaData = this.#getUrlMetaData();
|
||||
if (!urlMetaData) {
|
||||
return false;
|
||||
@@ -640,6 +652,7 @@ export class UrlbarValueFormatter {
|
||||
@@ -650,6 +662,7 @@ export class UrlbarValueFormatter {
|
||||
this.#window.requestAnimationFrame(() => {
|
||||
if (instance == this.#resizeInstance) {
|
||||
this.#ensureFormattedHostVisible();
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
diff --git a/browser/components/urlbar/content/UrlbarInput.mjs b/browser/components/urlbar/content/UrlbarInput.mjs
|
||||
index d6615ec5a29f3e3327ac4171f3fc5d9a69bd09fe..e1128b0d7f5accfd48af27f99e3b2e6463b45191 100644
|
||||
index 0fba59d62af9d3cd05bfee2cf84cd8b7cf9bfd6e..3997a5109267f378b59aa6510cbacd07ed57bd36 100644
|
||||
--- a/browser/components/urlbar/content/UrlbarInput.mjs
|
||||
+++ b/browser/components/urlbar/content/UrlbarInput.mjs
|
||||
@@ -98,6 +98,13 @@ const lazy = XPCOMUtils.declareLazy({
|
||||
@@ -16,7 +16,7 @@ index d6615ec5a29f3e3327ac4171f3fc5d9a69bd09fe..e1128b0d7f5accfd48af27f99e3b2e64
|
||||
const UNLIMITED_MAX_RESULTS = 99;
|
||||
|
||||
let getBoundsWithoutFlushing = element =>
|
||||
@@ -743,7 +750,16 @@ ${
|
||||
@@ -770,7 +777,16 @@ ${
|
||||
// See _on_select(). HTMLInputElement.select() dispatches a "select"
|
||||
// event but does not set the primary selection.
|
||||
this._suppressPrimaryAdjustment = true;
|
||||
@@ -27,13 +27,13 @@ index d6615ec5a29f3e3327ac4171f3fc5d9a69bd09fe..e1128b0d7f5accfd48af27f99e3b2e64
|
||||
+ zenToolbox.hasAttribute("zen-user-show")
|
||||
+ ));
|
||||
this.inputField.select();
|
||||
+ this.document.ownerGlobal.setTimeout(() => {
|
||||
+ this.document.documentGlobal.setTimeout(() => {
|
||||
+ this.window.document.documentElement.removeAttribute("supress-primary-adjustment");
|
||||
+ }, 0);
|
||||
this._suppressPrimaryAdjustment = false;
|
||||
}
|
||||
|
||||
@@ -817,6 +833,10 @@ ${
|
||||
@@ -844,6 +860,10 @@ ${
|
||||
hideSearchTerms = false,
|
||||
isSameDocument = false,
|
||||
} = {}) {
|
||||
@@ -44,11 +44,10 @@ index d6615ec5a29f3e3327ac4171f3fc5d9a69bd09fe..e1128b0d7f5accfd48af27f99e3b2e64
|
||||
if (!this.#isAddressbar) {
|
||||
throw new Error(
|
||||
"Cannot set URI for UrlbarInput that is not an address bar"
|
||||
@@ -1106,8 +1126,16 @@ ${
|
||||
return;
|
||||
}
|
||||
@@ -1138,7 +1158,16 @@ ${
|
||||
this.searchModeSwitcher?.updateSearchIcon();
|
||||
}
|
||||
-
|
||||
|
||||
+ const zenToolbox = this.document.getElementById("navigator-toolbox");
|
||||
+ this.window.document.documentElement.setAttribute("supress-primary-adjustment", !(
|
||||
+ zenToolbox.hasAttribute("zen-has-hover") ||
|
||||
@@ -56,13 +55,13 @@ index d6615ec5a29f3e3327ac4171f3fc5d9a69bd09fe..e1128b0d7f5accfd48af27f99e3b2e64
|
||||
+ zenToolbox.hasAttribute("zen-user-show")
|
||||
+ ));
|
||||
this.handleNavigation({ event });
|
||||
+ this.document.ownerGlobal.setTimeout(() => {
|
||||
+ this.document.documentGlobal.setTimeout(() => {
|
||||
+ this.window.document.documentElement.removeAttribute("supress-primary-adjustment");
|
||||
+ }, 100);
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -1551,7 +1579,11 @@ ${
|
||||
@@ -1627,7 +1656,11 @@ ${
|
||||
}
|
||||
|
||||
if (!this.#providesSearchMode(result)) {
|
||||
@@ -75,7 +74,7 @@ index d6615ec5a29f3e3327ac4171f3fc5d9a69bd09fe..e1128b0d7f5accfd48af27f99e3b2e64
|
||||
}
|
||||
|
||||
if (isCanonized) {
|
||||
@@ -2858,6 +2890,42 @@ ${
|
||||
@@ -2936,6 +2969,42 @@ ${
|
||||
await this.#updateLayoutBreakoutDimensions();
|
||||
}
|
||||
|
||||
@@ -126,7 +125,7 @@ index d6615ec5a29f3e3327ac4171f3fc5d9a69bd09fe..e1128b0d7f5accfd48af27f99e3b2e64
|
||||
|
||||
this.#updateTextboxPosition();
|
||||
|
||||
this.setAttribute("breakout-extend", "true");
|
||||
this.toggleAttribute("breakout-extend", true);
|
||||
|
||||
+ this.window.gZenUIManager.onUrlbarOpen();
|
||||
+ if (this.zenUrlbarBehavior == 'float' || (this.zenUrlbarBehavior == 'floating-on-type' && !this.focusedViaMousedown)) {
|
||||
@@ -144,9 +143,11 @@ index d6615ec5a29f3e3327ac4171f3fc5d9a69bd09fe..e1128b0d7f5accfd48af27f99e3b2e64
|
||||
|
||||
+ if (this._zenHandleUrlbarClose) {
|
||||
+ this._zenHandleUrlbarClose();
|
||||
+ } else if (!this._untrimmedValue || this.searchMode) {
|
||||
+ } else if (!this._untrimmedValue || (this.#isAddressbar && (this.searchMode || this.window.gZenVerticalTabsManager._hasSetSingleToolbar))) {
|
||||
+ // Restore the current page URL when the urlbar is empty on blur
|
||||
+ this.handleRevert();
|
||||
+ this.window.requestAnimationFrame(() => {
|
||||
+ this.handleRevert();
|
||||
+ });
|
||||
+ }
|
||||
+
|
||||
+ // Arc like URLbar: Blur the input on exit
|
||||
@@ -157,7 +158,7 @@ index d6615ec5a29f3e3327ac4171f3fc5d9a69bd09fe..e1128b0d7f5accfd48af27f99e3b2e64
|
||||
+ zenToolbox.hasAttribute("zen-user-show")
|
||||
+ ));
|
||||
+ this.window.gBrowser.selectedBrowser.focus();
|
||||
+ this.document.ownerGlobal.setTimeout(() => {
|
||||
+ this.document.documentGlobal.setTimeout(() => {
|
||||
+ this.window.document.documentElement.removeAttribute("supress-primary-adjustment");
|
||||
+ }, 100);
|
||||
+ this.window.gZenUIManager.onUrlbarClose();
|
||||
@@ -180,6 +181,7 @@ index d6615ec5a29f3e3327ac4171f3fc5d9a69bd09fe..e1128b0d7f5accfd48af27f99e3b2e64
|
||||
@@ -3031,10 +3129,12 @@ export class UrlbarInput extends HTMLElement {
|
||||
return;
|
||||
}
|
||||
|
||||
this.style.top = px(
|
||||
+ this.window.gZenVerticalTabsManager._hasSetSingleToolbar ?
|
||||
this.parentNode.getBoxQuads({
|
||||
|
||||
Reference in New Issue
Block a user