mirror of
https://github.com/kkapsner/CanvasBlocker
synced 2025-07-04 20:46:39 +02:00
parent
d35ffe0b70
commit
dd3620cd08
3 changed files with 9 additions and 8 deletions
11
lib/main.js
11
lib/main.js
|
@ -64,6 +64,10 @@
|
|||
browser.pageAction.show(port.sender.tab.id);
|
||||
}
|
||||
}
|
||||
if (data.hasOwnProperty("canvasBlocker-clear-page-action")){
|
||||
notice("Hide page action for tab", port.sender.tab.id);
|
||||
browser.pageAction.hide(port.sender.tab.id);
|
||||
}
|
||||
verbose("got data", data, "from port", port);
|
||||
});
|
||||
});
|
||||
|
@ -80,13 +84,6 @@
|
|||
});
|
||||
}
|
||||
});
|
||||
|
||||
// hide page action when a tab is refreshed
|
||||
browser.tabs.onUpdated.addListener(function(tabId, data){
|
||||
if (data.status && data.status === "loading"){
|
||||
browser.pageAction.hide(tabId);
|
||||
}
|
||||
});
|
||||
});
|
||||
|
||||
browser.runtime.onInstalled.addListener(function(){
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue