rk さんが書きました:
config 情報を変更するにはどのようにすればいいのでしょうか?
browser.download.useDownloadDirをトグルする項目をContentAreaContextMenuに追加するuserChrome.js用のスクリプトです。
拡張を作ったことが無いのでこれが参考になるかはわかりませんが……。
コード:
(function() {
  var menuitem = document.createElement("menuitem");
  menuitem.setAttribute("id", "toggleUseDir");
  menuitem.setAttribute("label", "toggleUseDIr");
  menuitem.addEventListener("click", function(aEvent) {
    try {
      var useDir = gBrowser.mPrefs.getBoolPref("browser.download.useDownloadDir");
    } catch(ex) {
      gBrowser.mPrefs.setBoolPref("browser.download.useDownloadDir", false);
    }
    if (useDir) { gBrowser.mPrefs.setBoolPref("browser.download.useDownloadDir", false); }
    else        { gBrowser.mPrefs.setBoolPref("browser.download.useDownloadDir", true); }
  }, false);
  var Popup = document.getElementById("contentAreaContextMenu");
  Popup.insertBefore(menuitem, Popup.firstChild);
})();