From 0bd3a67cb79f03ba3e01accfd0cfa7a7b1016a28 Mon Sep 17 00:00:00 2001 From: Ximi1970 Date: Mon, 11 Jul 2022 22:30:29 +0200 Subject: [PATCH 1/2] Remove old code --- webext/js/windowEvent.js | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/webext/js/windowEvent.js b/webext/js/windowEvent.js index 1dcaa33..a633a0f 100644 --- a/webext/js/windowEvent.js +++ b/webext/js/windowEvent.js @@ -1,4 +1,4 @@ -/// This is the important part. It implements the functions and events defined in schema.json. +// This is the important part. It implements the functions and events defined in schema.json. // The variable must have the same name you've been using so far, "myapi" in this case. var windowEvent = class extends ExtensionCommon.ExtensionAPI { getAPI(context) { @@ -41,12 +41,6 @@ var windowEvent = class extends ExtensionCommon.ExtensionAPI { // This function is called if the extension is disabled or removed, or Thunderbird closes. // We registered it with callOnClose, above. console.log("windowEvent API closed"); - - // Unload the JSM we imported above. This will cause Thunderbird to forget about the JSM, and - // load it afresh next time `import` is called. (If you don't call `unload`, Thunderbird will - // remember this version of the module and continue to use it, even if your extension receives - // an update.) You should *always* unload JSMs provided by your extension. - Cu.unload(extension.getURL("modules/windowEvent.jsm")); } }; From bc9df9a6ba04d64a916173e45e71e96fe5dbffeb Mon Sep 17 00:00:00 2001 From: Ximi1970 Date: Mon, 11 Jul 2022 22:45:16 +0200 Subject: [PATCH 2/2] Remove obsolete file --- webext/modules/windowEvent.jsm | 13 ------------- 1 file changed, 13 deletions(-) delete mode 100644 webext/modules/windowEvent.jsm diff --git a/webext/modules/windowEvent.jsm b/webext/modules/windowEvent.jsm deleted file mode 100644 index 9318337..0000000 --- a/webext/modules/windowEvent.jsm +++ /dev/null @@ -1,13 +0,0 @@ -var EXPORTED_SYMBOLS = ["windowEvent"]; - -var windowEvent = { - value : 0, - incValue: function() { - this.value++; - }, - getValue: function() { - return this.value; - }, -}; - -console.log("Loading windowEvent.jsm");