add: window.crypto.enableSmartCardEvents = true; document.addEventListener("smartcard-insert", onSmartCardChange, false); document.addEventListener("smartcard-remove", onSmartCardChange, false);  
context: function LoadCerts(){  certdb = Components.classes[nsX509CertDB].getService(nsIX509CertDB);  var certcache = Components.classes[nsNSSCertCache].createInstance(nsINSSCertCache);    certcache.cacheAllCerts();  caTreeView = Components.classes[nsCertTree]                    .createInstance(nsICertTree);  caTreeView.loadCertsFromCache(certcache, nsIX509Cert.CA_CERT);  document.getElementById('ca-tree')   .treeBoxObject.view = caTreeView;  serverTreeView = Components.classes[nsCertTree]                        .createInstance(nsICertTree);  serverTreeView.loadCertsFromCache(certcache, nsIX509Cert.SERVER_CERT);  document.getElementById('server-tree')   .treeBoxObject.view = serverTreeView;  emailTreeView = Components.classes[nsCertTree]                       .createInstance(nsICertTree);  emailTreeView.loadCertsFromCache(certcache, nsIX509Cert.EMAIL_CERT);  document.getElementById('email-tree')   .treeBoxObject.view = emailTreeView;   userTreeView = Components.classes[nsCertTree]                      .createInstance(nsICertTree);  userTreeView.loadCertsFromCache(certcache, nsIX509Cert.USER_CERT);  document.getElementById('user-tree')   .treeBoxObject.view = userTreeView;  var rowCnt = userTreeView.rowCount;  var enableBackupAllButton=document.getElementById('mine_backupAllButton');  if(rowCnt < 1) {    enableBackupAllButton.setAttribute("disabled",true);  } else  {    enableBackupAllButton.setAttribute("enabled",true);  }  if (certdb.isOcspOn) {    document.getElementById('ocsp_info').removeAttribute("hidden");  }}
meta: 5872	/local1/tlutelli/issta_data/temp/all_js/javascript/2006_temp/2006/5872/3561900b877ad18bbbfbfbcbe6d89f0be1be201f/certManager.js/clean/security/manager/pki/resources/content/certManager.js