Grammalecte  Check-in [2e0c8273f1]

Overview
Comment:[fx][fr][bug] conj: initialisation incorrecte pour les content-scripts
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | fx | webext2
Files: files | file ages | folders
SHA3-256: 2e0c8273f14b6f586916d360733d4316eeca5b8d807592e9990aaa8b54a5cf40
User & Date: olr on 2017-08-06 20:54:10
Other Links: branch diff | manifest | tags
Context
2017-08-07
07:57
[fx] panel: CSS adjustments check-in: 8a81843b4a user: olr tags: fx, webext2
2017-08-06
20:54
[fx][fr][bug] conj: initialisation incorrecte pour les content-scripts check-in: 2e0c8273f1 user: olr tags: fx, webext2
13:40
[build] paths for Firefox on Windows and on Linux check-in: 7ba08610f3 user: olr tags: build, webext2
Changes

Modified gc_lang/fr/modules-js/conj.js from [ab8249cda2] to [abb72eabf4].

481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
if (typeof(browser) !== 'undefined') {
    // WebExtension (but not in Worker)
    conj.init(helpers.loadFile(browser.extension.getURL("grammalecte/fr/conj_data.json")));
} else if (typeof(require) !== 'undefined') {
    // Add-on SDK and Thunderbird
    let helpers = require("resource://grammalecte/helpers.js");
    conj.init(helpers.loadFile("resource://grammalecte/fr/conj_data.json"));
} else if (typeof(self) !== 'undefined' && typeof(self.port) !== 'undefined' && typeof(self.port.on) === "undefined") {
    // used within Firefox content script (conjugation panel).
    // can’t load JSON from here, so we do it in ui.js and send it here.
    self.port.on("provideConjData", function (sJSONData) {
        conj.init(sJSONData);
    });    
} else {
    console.log("Module conj non initialisé");







|







481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
if (typeof(browser) !== 'undefined') {
    // WebExtension (but not in Worker)
    conj.init(helpers.loadFile(browser.extension.getURL("grammalecte/fr/conj_data.json")));
} else if (typeof(require) !== 'undefined') {
    // Add-on SDK and Thunderbird
    let helpers = require("resource://grammalecte/helpers.js");
    conj.init(helpers.loadFile("resource://grammalecte/fr/conj_data.json"));
} else if (typeof(self) !== 'undefined' && typeof(self.port) !== 'undefined' && typeof(self.port.on) !== "undefined") {
    // used within Firefox content script (conjugation panel).
    // can’t load JSON from here, so we do it in ui.js and send it here.
    self.port.on("provideConjData", function (sJSONData) {
        conj.init(sJSONData);
    });    
} else {
    console.log("Module conj non initialisé");