add: var customizePopup = document.getElementById("CustomizeMailToolbar"); customizePopup.setAttribute("disabled", "true"); 
context: function CustomizeMailToolbar(id){  // Disable the toolbar context menu items  var menubar = document.getElementById("mail-menubar");  for (var i = 0; i < menubar.childNodes.length; ++i)    menubar.childNodes[i].setAttribute("disabled", true);      //var cmd = document.getElementById("cmd_CustomizeToolbars");  //cmd.setAttribute("disabled", "true");      window.openDialog("chrome://global/content/customizeToolbar.xul", "CustomizeToolbar",                     "chrome,all,dependent", document.getElementById(id));}
meta: 9421	/local1/tlutelli/issta_data/temp/all_js/javascript/2006_temp/2006/9421/55f656dc1f765512e79d7c79c5fdbe6da3b32803/mailCore.js/buggy/mail/base/content/mailCore.js