Bug 1389721 - fix page action menu to deal with not being passed an event, so the 'save link to pocket' context menu works, r=jaws
This also removes the now-obsolete onBeforeCommand method from the pocket code. MozReview-Commit-ID: EjrMoAIv3xw
This commit is contained in:
@@ -461,7 +461,7 @@ var BrowserPageActions = {
|
||||
},
|
||||
|
||||
doCommandForAction(action, event, buttonNode) {
|
||||
if (event.type == "click" && event.button != 0) {
|
||||
if (event && event.type == "click" && event.button != 0) {
|
||||
return;
|
||||
}
|
||||
PageActions.logTelemetry("used", action, buttonNode);
|
||||
|
||||
@@ -32,10 +32,6 @@ var Pocket = {
|
||||
/**
|
||||
* Functions related to the Pocket panel UI.
|
||||
*/
|
||||
onBeforeCommand(event) {
|
||||
BrowserUtils.setToolbarButtonHeightProperty(event.target);
|
||||
},
|
||||
|
||||
onShownInPhotonPageActionPanel(panel, iframe) {
|
||||
let window = panel.ownerGlobal;
|
||||
window.pktUI.setPhotonPageActionPanelFrame(iframe);
|
||||
|
||||
Reference in New Issue
Block a user