Show default profile in context menu

This commit is contained in:
tunefish 2018-03-16 19:25:23 +01:00
parent 0edb67224d
commit 884b55c679

View file

@ -188,7 +188,7 @@ const assignManager = {
active: info.frameId !== undefined,
cookieStoreId: reopenCookieStoreId,
index: tab.index + 1,
openerTabId: tab.id,
openerTabId: tab.openerTabId,
pinned: tab.pinned,
url: tab.url,
}).then(() => {
@ -362,6 +362,20 @@ const assignManager = {
contexts: ["all", "tab"],
});
browser.contextMenus.create({
id: this.getCookieStoreIdFromReloadMenuId("firefox-default"),
title: "Default",
contexts: ["all", "tab"],
parentId: this.MENU_RELOAD_IN,
});
browser.contextMenus.create({
id: "reopen-separator",
contexts: ["all", "tab"],
type: "separator",
parentId: this.MENU_RELOAD_IN,
});
const identities = await browser.contextualIdentities.query({});
identities.forEach((identity) => {
this.addContainerMenuEntry(identity, (identity.cookieStoreId !== tab.cookieStoreId) ?