mirror of
https://github.com/zen-browser/desktop.git
synced 2025-10-04 00:46:35 +00:00
Fixed pinning and unpinning extensions messing up the toolbar
This commit is contained in:
@@ -1,17 +1,27 @@
|
|||||||
diff --git a/browser/base/content/browser-addons.js b/browser/base/content/browser-addons.js
|
diff --git a/browser/base/content/browser-addons.js b/browser/base/content/browser-addons.js
|
||||||
index 992d07daaef1abc4554a43aa654888f66963c575..6db4dd3864375da4b83a3a6f1a656403f324093e 100644
|
index 992d07daaef1abc4554a43aa654888f66963c575..73e620b70b7ed14e9d140e875c2cd5f5ac31456b 100644
|
||||||
--- a/browser/base/content/browser-addons.js
|
--- a/browser/base/content/browser-addons.js
|
||||||
+++ b/browser/base/content/browser-addons.js
|
+++ b/browser/base/content/browser-addons.js
|
||||||
@@ -2113,10 +2113,12 @@ var gUnifiedExtensions = {
|
@@ -2105,18 +2105,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_NAVBAR
|
||||||
: CustomizableUI.AREA_ADDONS;
|
: CustomizableUI.AREA_ADDONS;
|
||||||
let newPosition = shouldPinToToolbar ? undefined : 0;
|
let newPosition = shouldPinToToolbar ? undefined : 0;
|
||||||
+ for (const window of CustomizableUI.windows) window.gZenVerticalTabsManager._preCustomize();
|
+ await gZenVerticalTabsManager._preCustomize();
|
||||||
|
|
||||||
CustomizableUI.addWidgetToArea(widgetId, newArea, newPosition);
|
CustomizableUI.addWidgetToArea(widgetId, newArea, newPosition);
|
||||||
|
|
||||||
this.updateAttention();
|
this.updateAttention();
|
||||||
+ for (const window of CustomizableUI.windows) window.gZenVerticalTabsManager._updateEvent();
|
+ await gZenVerticalTabsManager._postCustomize();
|
||||||
},
|
},
|
||||||
|
|
||||||
async moveWidget(menu, direction) {
|
async moveWidget(menu, direction) {
|
||||||
|
@@ -1082,7 +1082,7 @@ menuitem[id='placesContext_new:separator'] {
|
|||||||
--fp-enabled: 1;
|
--fp-enabled: 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
@media not (-moz-platform: 'linux') {
|
@media not (-moz-platform: linux) {
|
||||||
.unified-extensions-context-menu-pin-to-toolbar {
|
.unified-extensions-context-menu-pin-to-toolbar {
|
||||||
--menu-image: url('pin.svg');
|
--menu-image: url('pin.svg');
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user