-
Notifications
You must be signed in to change notification settings - Fork 54
/
background.js
16 lines (12 loc) · 716 Bytes
/
background.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
function handleUpdateAvailable(details) {
console.log("Update available for TbSync");
}
async function main() {
// just by registering this listener, updates will not install until next restart
//messenger.runtime.onUpdateAvailable.addListener(handleUpdateAvailable);
await messenger.BootstrapLoader.registerChromeUrl([ ["content", "tbsync", "content/"] ]);
await messenger.BootstrapLoader.registerOptionsPage("chrome://tbsync/content/manager/addonoptions.xhtml");
await messenger.BootstrapLoader.registerBootstrapScript("chrome://tbsync/content/scripts/bootstrap.js");
}
main();
messenger.browserAction.onClicked.addListener(tab => { messenger.BootstrapLoader.openOptionsDialog(tab.windowId); });