188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
|
contexts: ["all"]
});
browser.contextMenus.onClicked.addListener(function (xInfo, xTab) {
// xInfo = https://developer.mozilla.org/en-US/Add-ons/WebExtensions/API/contextMenus/OnClickData
// xTab = https://developer.mozilla.org/en-US/Add-ons/WebExtensions/API/tabs/Tab
// confusing: no way to get the node where we click?!
switch (xInfo.menuItemId) {
case "parseAndSpellcheck":
parseAndSpellcheckSelectedText(xTab.id, xInfo.selectionText);
break;
case "getListOfTokens":
getListOfTokensFromSelectedText(xTab.id, xInfo.selectionText);
|
<
|
188
189
190
191
192
193
194
195
196
197
198
199
200
201
|
contexts: ["all"]
});
browser.contextMenus.onClicked.addListener(function (xInfo, xTab) {
// xInfo = https://developer.mozilla.org/en-US/Add-ons/WebExtensions/API/contextMenus/OnClickData
// xTab = https://developer.mozilla.org/en-US/Add-ons/WebExtensions/API/tabs/Tab
// confusing: no way to get the node where we click?!
switch (xInfo.menuItemId) {
case "parseAndSpellcheck":
parseAndSpellcheckSelectedText(xTab.id, xInfo.selectionText);
break;
case "getListOfTokens":
getListOfTokensFromSelectedText(xTab.id, xInfo.selectionText);
|