home *** CD-ROM | disk | FTP | other *** search
/ Chip 2003 November / Chip_2003-11_cd2.bin / nav2004 / download / NAV / External / NORTON / APP / NAVComUI.dll / HTML / INOCULATIONACTION.JS < prev    next >
Text File  |  2003-08-17  |  2KB  |  66 lines

  1. var InocUI = window.external.ObjectArg;
  2. var MainFrame = window.parent;
  3.  
  4. // Inoculation Actions
  5. var InocAction_Update     = 0;
  6. var InocAction_Restore    = 1;
  7. var InocAction_Ignore    = 2;
  8.  
  9. // Inoculation Types
  10. var InocType_BootRecord            = 0;
  11. var InocType_MasterBootRecord    = 1;
  12.  
  13. var bNotifyOnly = false;
  14.  
  15. function OnLoad()
  16. {
  17.     OkButton.focus();
  18.     
  19.     bNotifyOnly = InocUI.NotifyOnly;
  20.  
  21.     if (bNotifyOnly == true)
  22.     {
  23.         // This is a notification dialog only, hide all inoculation actions/choices
  24.         InocText2.style.display = "none";
  25.         InocActionRow.style.display = "none";
  26.     }
  27.     else
  28.     {
  29.         InocText2.style.display = "";
  30.         InocActionRow.style.display = "";
  31.     }
  32.     
  33.     if (InocUI.InocType == InocType_BootRecord)
  34.     {
  35.         MasterBootRecordAlert.style.display = "none";
  36.         BootRecordAlert.style.display = "";
  37.         
  38.         for (i = 0; i < MainFrame.MasterBootRecord.length; i++)
  39.         {
  40.             MainFrame.MasterBootRecord[i].style.display = "none";
  41.         }
  42.         for (i = 0; i < MainFrame.BootRecord.length; i++)
  43.         {
  44.             MainFrame.BootRecord[i].style.display = "";
  45.         }
  46.     }
  47. }
  48.  
  49. function OnOkButton()
  50. {
  51.     if (bNotifyOnly == true)
  52.     {
  53.         InocUI.InocAction = InocAction_Ignore;
  54.     }
  55.     else
  56.     {
  57.         if (MainFrame.UpdateInoculation.checked == true)
  58.             InocUI.InocAction = InocAction_Update;
  59.         else if (MainFrame.RestoreInoculation.checked == true)
  60.             InocUI.InocAction = InocAction_Restore;
  61.         else if (MainFrame.IgnoreInoculation.checked == true)
  62.             InocUI.InocAction = InocAction_Ignore;
  63.     }
  64.         
  65.     MainFrame.navigate("res://closeme.xyz");    
  66. }