diff --git a/simple-translate/background.js b/simple-translate/background.js index fd7ef31..9b83317 100644 --- a/simple-translate/background.js +++ b/simple-translate/background.js @@ -27,6 +27,12 @@ function showMenu() { //メニューを表示 function menuCreate() { + browser.contextMenus.create({ + id: "translatePageOnTab", + title: browser.i18n.getMessage("translatePageMenu"), + contexts: ["tab"], + }); + browser.contextMenus.create({ id: "translatePage", title: browser.i18n.getMessage("translatePageMenu"), @@ -56,6 +62,7 @@ function menuRemove() { browser.contextMenus.onClicked.addListener(function (info, tab) { switch (info.menuItemId) { case "translatePage": + case "translatePageOnTab": translatePageMenu(info, tab); break; case "translateText":