mirror of
https://github.com/zen-browser/desktop.git
synced 2025-11-09 20:15:03 +00:00
94 lines
3.6 KiB
C++
94 lines
3.6 KiB
C++
diff --git a/browser/base/content/browser-addons.js b/browser/base/content/browser-addons.js
|
|
index f33a300eb0eed74e286da24919ad3e8505f632c3..9f400e887424693d0ecceb9db79fccf2bd5a757d 100644
|
|
--- a/browser/base/content/browser-addons.js
|
|
+++ b/browser/base/content/browser-addons.js
|
|
@@ -1069,7 +1069,7 @@ var gXPInstallObserver = {
|
|
persistent: true,
|
|
hideClose: true,
|
|
popupOptions: {
|
|
- position: "bottomright topright",
|
|
+ position: gZenUIManager.panelUIPosition(),
|
|
},
|
|
};
|
|
|
|
@@ -1279,7 +1279,7 @@ var gXPInstallObserver = {
|
|
hideClose: true,
|
|
timeout: Date.now() + 30000,
|
|
popupOptions: {
|
|
- position: "bottomright topright",
|
|
+ position: gZenUIManager.panelUIPosition(),
|
|
},
|
|
};
|
|
|
|
@@ -2211,7 +2211,7 @@ var gUnifiedExtensions = {
|
|
// If the new ID is not added in NOTIFICATION_IDS, consider handling the case
|
|
// in the "PopupNotificationsBeforeAnchor" handler elsewhere in this file.
|
|
getPopupAnchorID(aBrowser, aWindow) {
|
|
- const anchorID = "unified-extensions-button";
|
|
+ const anchorID = "zen-site-data-icon-button";
|
|
const attr = anchorID + "popupnotificationanchor";
|
|
|
|
if (!aBrowser[attr]) {
|
|
@@ -2222,7 +2222,7 @@ var gUnifiedExtensions = {
|
|
anchorID
|
|
// Anchor on the toolbar icon to position the popup right below the
|
|
// button.
|
|
- ).firstElementChild;
|
|
+ );
|
|
}
|
|
|
|
return anchorID;
|
|
@@ -2646,11 +2646,7 @@ var gUnifiedExtensions = {
|
|
// Lazy load the unified-extensions-panel panel the first time we need to
|
|
// display it.
|
|
if (!this._panel) {
|
|
- let template = document.getElementById(
|
|
- "unified-extensions-panel-template"
|
|
- );
|
|
- template.replaceWith(template.content);
|
|
- this._panel = document.getElementById("unified-extensions-panel");
|
|
+ this._panel = document.getElementById("zen-unified-site-data-panel");
|
|
let customizationArea = this._panel.querySelector(
|
|
"#unified-extensions-area"
|
|
);
|
|
@@ -2703,6 +2699,7 @@ var gUnifiedExtensions = {
|
|
// and no alternative content is available for display in the panel.
|
|
const policies = this.getActivePolicies();
|
|
if (
|
|
+ false &&
|
|
policies.length &&
|
|
!this.hasExtensionsInPanel(policies) &&
|
|
!this.isPrivateWindowMissingExtensionsWithoutPBMAccess() &&
|
|
@@ -2743,7 +2740,7 @@ var gUnifiedExtensions = {
|
|
this.recordButtonTelemetry(reason || "extensions_panel_showing");
|
|
this.ensureButtonShownBeforeAttachingPanel(panel);
|
|
PanelMultiView.openPopup(panel, this._button, {
|
|
- position: "bottomright topright",
|
|
+ position: gZenUIManager.panelUIPosition(panel, this._button),
|
|
triggerEvent: aEvent,
|
|
});
|
|
}
|
|
@@ -2930,18 +2927,20 @@ var gUnifiedExtensions = {
|
|
this._maybeMoveWidgetNodeBack(widgetId);
|
|
}
|
|
|
|
- this.pinToToolbar(widgetId, shouldPinToToolbar);
|
|
+ await this.pinToToolbar(widgetId, shouldPinToToolbar);
|
|
},
|
|
|
|
- pinToToolbar(widgetId, shouldPinToToolbar) {
|
|
+ async pinToToolbar(widgetId, shouldPinToToolbar) {
|
|
let newArea = shouldPinToToolbar
|
|
? CustomizableUI.AREA_NAVBAR
|
|
: CustomizableUI.AREA_ADDONS;
|
|
let newPosition = shouldPinToToolbar ? undefined : 0;
|
|
+ await gZenVerticalTabsManager._preCustomize();
|
|
|
|
CustomizableUI.addWidgetToArea(widgetId, newArea, newPosition);
|
|
// addWidgetToArea() will trigger onWidgetAdded or onWidgetMoved as needed,
|
|
// and our handlers will call updateAttention() as needed.
|
|
+ await gZenVerticalTabsManager._postCustomize();
|
|
},
|
|
|
|
async moveWidget(menu, direction) {
|