MCPcopy
hub / github.com/RetireJS/retire.js / onUnload

Function onUnload

firefox/lib/main.js:79–85  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

77
78 // Add an unload listener to the tab's page in order to reset the button badge on back/forward cache (bfCache)
79 function onUnload() {
80 if (tabs.activeTab.id == tabId) {
81 console.log("unload");
82 updateButton(null);
83 tabUtil.getTabContentWindow(firefox.getBrowserTabElement(tabId)).removeEventListener("unload", onUnload);
84 }
85 }
86 tabUtil.getTabContentWindow(firefox.getBrowserTabElement(tabId)).addEventListener("unload", onUnload);
87
88 console.log("tab ready: " + tabId);

Callers

nothing calls this directly

Calls 1

updateButtonFunction · 0.85

Tested by

no test coverage detected