Grammalecte  options.js at [c5e22a2cb4]

File gc_lang/fr/tb/content/options.js artifact 7635023546 part of check-in c5e22a2cb4


// JavaScript

"use strict";


const Cc = Components.classes;
const Ci = Components.interfaces;
// const Cu = Components.utils;
const prefs = Cc["@mozilla.org/preferences-service;1"].getService(Ci.nsIPrefService).getBranch("extensions.grammarchecker.");


var oOptControl = {

    load: function () {
        try {
            document.getElementById('check_signature').checked = prefs.getBoolPref('bCheckSignature');
        }
        catch (e) {
            console.error(e);
            // Cu.reportError(e);
        }
    },

    save: function () {
        try {
            prefs.setBoolPref('bCheckSignature', document.getElementById('check_signature').checked);
        }
        catch (e) {
            console.error(e);
            // Cu.reportError(e);
        }
    }
}


oOptControl.load();