home *** CD-ROM | disk | FTP | other *** search
/ GameStar 2006 January / Gamestar_80_2006-01_dvd.iso / Utility / 5-11_xp-2k_dd_ccc_wdm_enu_27345.exe / Data1.cab / _516690A2CC7549B9A84E74D9E091C845 < prev    next >
Text File  |  2003-09-15  |  35KB  |  1,325 lines

  1. // Copyright (c) 2000-2003 Quadralay Corporation.  All rights reserved.
  2. //
  3.  
  4. function  WWHHelp_Object(ParamURL)
  5. {
  6.   var  URLParams;
  7.  
  8.  
  9.   this.mbInitialized        = false;
  10.   this.mbAccessible         = false;
  11.   this.mInitialTabName      = null;
  12.   this.mInitStage           = 0;
  13.   this.mSettings            = new WWHCommonSettings_Object();
  14.   this.mMessages            = new WWHCommonMessages_Object();
  15.   this.mDocumentLoaded      = null;
  16.   this.mLocationURL         = WWHFrame.WWHBrowser.fNormalizeURL(ParamURL);
  17.   this.mBaseURL             = WWHStringUtilities_GetBaseURL(this.mLocationURL);
  18.   this.mHelpURLPrefix       = WWHFrame.WWHBrowser.fRestoreEscapedSpaces(this.mBaseURL);
  19.   this.mContextDir          = null;
  20.   this.mTopicTag            = null;
  21.   this.mDocumentURL         = "";
  22.   this.mPopup               = null;
  23.   this.mPopupContext        = "";
  24.   this.mPopupLink           = "";
  25.   this.mBookGroups          = new WWHBookGroups_Object();
  26.   this.mBooks               = new WWHBookList_Object();
  27.   this.mFavoritesCookie     = "WWH" + this.mSettings.mCookiesID + "_Favs";
  28.   this.mbIgnoreNextKeyPress = false;
  29.   this.mbAltKeyDown         = false;
  30.   this.mAccessKey           = -1;
  31.   this.mbAutoSyncTOC        = false;
  32.  
  33.   this.fSingleTopic                    = WWHHelp_SingleTopic;
  34.   this.fGetFrameReference              = WWHHelp_GetFrameReference;
  35.   this.fSetLocation                    = WWHHelp_SetLocation;
  36.   this.fReplaceLocation                = WWHHelp_ReplaceLocation;
  37.   this.fReloadLocation                 = WWHHelp_ReloadLocation;
  38.   this.fGetURLParameters               = WWHHelp_GetURLParameters;
  39.   this.fCookiesEnabled                 = WWHHelp_CookiesEnabled;
  40.   this.fInitStage                      = WWHHelp_InitStage;
  41.   this.fHandlerInitialized             = WWHHelp_HandlerInitialized;
  42.   this.fGetFrameName                   = WWHHelp_GetFrameName;
  43.   this.fSetFrameName                   = WWHHelp_SetFrameName;
  44.   this.fSetDocumentFrameWithURL        = WWHHelp_SetDocumentFrameWithURL;
  45.   this.fSetDocumentFrame               = WWHHelp_SetDocumentFrame;
  46.   this.fSetDocumentHREF                = WWHHelp_SetDocumentHREF;
  47.   this.fGetBookIndexFileIndexURL       = WWHHelp_GetBookIndexFileIndexURL;
  48.   this.fDetermineContextDocument       = WWHHelp_DetermineContextDocument;
  49.   this.fLoadTopicData                  = WWHHelp_LoadTopicData;
  50.   this.fProcessTopicResult             = WWHHelp_ProcessTopicResult;
  51.   this.fDisplayContextDocument         = WWHHelp_DisplayContextDocument;
  52.   this.fSetContextDocument             = WWHHelp_SetContextDocument;
  53.   this.fGetBookFileHREF                = WWHHelp_GetBookFileHREF;
  54.   this.fHREFToBookIndexFileIndexAnchor = WWHHelp_HREFToBookIndexFileIndexAnchor;
  55.   this.fGetSyncPrevNext                = WWHHelp_GetSyncPrevNext;
  56.   this.fHREFToTitle                    = WWHHelp_HREFToTitle;
  57.   this.fPopupHTML                      = WWHHelp_PopupHTML;
  58.   this.fShowPopup                      = WWHHelp_ShowPopup;
  59.   this.fHidePopup                      = WWHHelp_HidePopup;
  60.   this.fClickedPopup                   = WWHHelp_ClickedPopup;
  61.   this.fGotoPopupTarget                = WWHHelp_GotoPopupTarget;
  62.   this.fGetPopupAccessibleHTML         = WWHHelp_GetPopupAccessibleHTML;
  63.   this.fDisplayFirst                   = WWHHelp_DisplayFirst;
  64.   this.fUpdate                         = WWHHelp_Update;
  65.   this.fSyncTOC                        = WWHHelp_SyncTOC;
  66.   this.fDocumentBookkeeping            = WWHHelp_DocumentBookkeeping;
  67.   this.fUnload                         = WWHHelp_Unload;
  68.   this.fIgnoreNextKeyPress             = WWHHelp_IgnoreNextKeyPress;
  69.   this.fHandleKeyDown                  = WWHHelp_HandleKeyDown;
  70.   this.fHandleKeyPress                 = WWHHelp_HandleKeyPress;
  71.   this.fHandleKeyUp                    = WWHHelp_HandleKeyUp;
  72.   this.fProcessAccessKey               = WWHHelp_ProcessAccessKey;
  73.   this.fFocus                          = WWHHelp_Focus;
  74.  
  75.   // Load up messages
  76.   //
  77.   this.mMessages.fSetByLocale(WWHFrame.WWHBrowser.mLocale);
  78.  
  79.   // Set cookie path
  80.   //
  81.   WWHFrame.WWHBrowser.fSetCookiePath(WWHStringUtilities_GetBaseURL(ParamURL));
  82.  
  83.   // Check URL parameters
  84.   //
  85.   URLParams = this.fGetURLParameters(this.mLocationURL);
  86.  
  87.   // Set accessibility flag
  88.   //
  89.   if (this.mSettings.mAccessible == "true")
  90.   {
  91.     this.mbAccessible = true;
  92.   }
  93.   else
  94.   {
  95.     if (URLParams[4] != null)
  96.     {
  97.       if (URLParams[4] == "true")
  98.       {
  99.         this.mbAccessible = true;
  100.       }
  101.     }
  102.   }
  103.  
  104.   // Determine initial flag
  105.   //
  106.   if (URLParams[5] != null)
  107.   {
  108.     this.mInitialTabName = URLParams[5];
  109.   }
  110.  
  111.   // Set popup capabilities
  112.   //
  113.   if (this.mbAccessible)
  114.   {
  115.     WWHFrame.WWHBrowser.mbSupportsPopups = false;
  116.   }
  117.  
  118.   // Create popup
  119.   //
  120.   this.mPopup = new WWHPopup_Object("WWHFrame.WWHHelp.mPopup",
  121.                                     this.fGetFrameReference("WWHDocumentFrame"),
  122.                                     WWHPopupFormat_Translate,
  123.                                     WWHPopupFormat_Format,
  124.                                     "WWHPopupDIV", "WWHPopupText", 500, 12, 20,
  125.                                     this.mSettings.mPopup.mWidth);
  126. }
  127.  
  128. function  WWHHelp_SingleTopic()
  129. {
  130.   var  bVarSingleTopic = false;
  131.  
  132.  
  133.   if (this.mLocationURL.indexOf("wwhelp/wwhimpl/common/html/wwhelp.htm") != -1)
  134.   {
  135.     bVarSingleTopic = true;
  136.   }
  137.  
  138.   return bVarSingleTopic;
  139. }
  140.  
  141. function  WWHHelp_GetFrameReference(ParamFrameName)
  142. {
  143.   var  VarFrameReference;
  144.  
  145.  
  146.   switch (ParamFrameName)
  147.   {
  148.     case "WWHFrame":
  149.       // WWHFrame
  150.       //
  151.       VarFrameReference = "WWHFrame";
  152.       break;
  153.  
  154.     case "WWHNavigationFrame":
  155.       // WWHFrame.WWHNavigationFrame
  156.       //
  157.       VarFrameReference = "WWHFrame.frames[0]";
  158.       break;
  159.  
  160.     case "WWHTabsFrame":
  161.     case "WWHPanelFrame":
  162.     case "WWHPanelNavigationFrame":
  163.     case "WWHPanelViewFrame":
  164.       // WWHFrame.WWHNavigationFrame.WWHTabsFrame
  165.       //
  166.       // WWHFrame.WWHNavigationFrame.WWHPanelFrame
  167.       //
  168.       // WWHFrame.WWHNavigationFrame.WWHPanelFrame.WWHPanelNavigationFrame
  169.       //
  170.       // WWHFrame.WWHNavigationFrame.WWHPanelFrame.WWHPanelViewFrame
  171.       //
  172.       VarFrameReference = WWHFrame.WWHHandler.fGetFrameReference(ParamFrameName);
  173.       break;
  174.  
  175.     case "WWHContentFrame":
  176.       // WWHFrame.WWHContentFrame
  177.       //
  178.       if (this.fSingleTopic())
  179.       {
  180.         VarFrameReference = "WWHFrame";
  181.       }
  182.       else
  183.       {
  184.         VarFrameReference = "WWHFrame.frames[1]";
  185.       }
  186.       break;
  187.  
  188.     case "WWHPageNavFrame":
  189.       // WWHFrame.WWHContentFrame.WWHPageNavFrame
  190.       //
  191.       VarFrameReference = this.fGetFrameReference("WWHContentFrame") + ".frames[0]";
  192.       break;
  193.  
  194.     case "WWHControlsLeftFrame":
  195.       // WWHFrame.WWHContentFrame.WWHPageNavFrame.WWHControlsLeftFrame
  196.       //
  197.       VarFrameReference = this.fGetFrameReference("WWHPageNavFrame") + ".frames[0]";
  198.       break;
  199.  
  200.     case "WWHTitleFrame":
  201.       // WWHFrame.WWHContentFrame.WWHPageNavFrame.WWHTitleFrame
  202.       //
  203.       VarFrameReference = this.fGetFrameReference("WWHPageNavFrame") + ".frames[1]";
  204.       break;
  205.  
  206.     case "WWHControlsRightFrame":
  207.       // WWHFrame.WWHContentFrame.WWHPageNavFrame.WWHControlsRightFrame
  208.       //
  209.       VarFrameReference = this.fGetFrameReference("WWHPageNavFrame") + ".frames[2]";
  210.       break;
  211.  
  212.     case "WWHDocumentFrame":
  213.       // WWHFrame.WWHContentFrame.WWHDocumentFrame
  214.       //
  215.       VarFrameReference = this.fGetFrameReference("WWHContentFrame") + ".frames[1]";
  216.       break;
  217.  
  218.     default:
  219.       VarFrameReference = null;
  220.       break;
  221.   }
  222.  
  223.   return VarFrameReference;
  224. }
  225.  
  226. function  WWHHelp_SetLocation(ParamFrame,
  227.                               ParamURL)
  228. {
  229.   var  VarFrameReference;
  230.  
  231.  
  232.   VarFrameReference = this.fGetFrameReference(ParamFrame);
  233.   WWHFrame.WWHBrowser.fSetLocation(VarFrameReference, ParamURL);
  234. }
  235.  
  236. function  WWHHelp_ReplaceLocation(ParamFrame,
  237.                                   ParamURL)
  238. {
  239.   var  VarFrameReference;
  240.  
  241.  
  242.   VarFrameReference = this.fGetFrameReference(ParamFrame);
  243.   WWHFrame.WWHBrowser.fReplaceLocation(VarFrameReference, ParamURL);
  244. }
  245.  
  246. function  WWHHelp_ReloadLocation(ParamFrame)
  247. {
  248.   var  VarFrameReference;
  249.  
  250.  
  251.   VarFrameReference = this.fGetFrameReference(ParamFrame);
  252.   WWHFrame.WWHBrowser.fReloadLocation(VarFrameReference);
  253. }
  254.  
  255. function  WWHHelp_GetURLParameters(ParamURL)
  256. {
  257.   var  URLParams = new Array(null, null, null, null, null, null);
  258.   var  Parts;
  259.   var  ContextMarker    = "context=";
  260.   var  TopicMarker      = "topic=";
  261.   var  FileMarker       = "file=";
  262.   var  HREFMarker       = "href=";
  263.   var  AccessibleMarker = "accessible=";
  264.   var  TabMarker        = "tab=";
  265.   var  MaxIndex;
  266.   var  Index;
  267.  
  268.  
  269.   // Check for possible context specification
  270.   //
  271.   if (ParamURL.indexOf("?") != -1)
  272.   {
  273.     // Get parameters
  274.     //
  275.     Parts = ParamURL.split("?");
  276.     Parts[0] = Parts[1];
  277.     Parts.length = 1;
  278.     if (Parts[0].indexOf("&") != -1)
  279.     {
  280.       Parts = Parts[0].split("&");
  281.     }
  282.  
  283.     // Process parameters
  284.     //
  285.     for (MaxIndex = Parts.length, Index = 0 ; Index < MaxIndex ; Index++)
  286.     {
  287.       if (Parts[Index].indexOf(ContextMarker) == 0)
  288.       {
  289.         URLParams[0] = Parts[Index].substring(ContextMarker.length, Parts[Index].length);
  290.       }
  291.       if (Parts[Index].indexOf(TopicMarker) == 0)
  292.       {
  293.         URLParams[1] = Parts[Index].substring(TopicMarker.length, Parts[Index].length);
  294.       }
  295.       if (Parts[Index].indexOf(FileMarker) == 0)
  296.       {
  297.         URLParams[2] = Parts[Index].substring(FileMarker.length, Parts[Index].length);
  298.       }
  299.       if (Parts[Index].indexOf(HREFMarker) == 0)
  300.       {
  301.         URLParams[3] = Parts[Index].substring(HREFMarker.length, Parts[Index].length);
  302.       }
  303.       if (Parts[Index].indexOf(AccessibleMarker) == 0)
  304.       {
  305.         URLParams[4] = Parts[Index].substring(AccessibleMarker.length, Parts[Index].length);
  306.       }
  307.       if (Parts[Index].indexOf(TabMarker) == 0)
  308.       {
  309.         URLParams[5] = Parts[Index].substring(TabMarker.length, Parts[Index].length);
  310.       }
  311.     }
  312.  
  313.     // Make certain we have both a ContextTag and either a TopicTag or FileTag
  314.     // Otherwise, reset them
  315.     //
  316.     if ((URLParams[0] == null) ||
  317.         ((URLParams[1] == null) &&
  318.          (URLParams[2] == null)))
  319.     {
  320.       URLParams[0] = null;
  321.       URLParams[1] = null;
  322.       URLParams[2] = null;
  323.     }
  324.   }
  325.  
  326.   return URLParams;
  327. }
  328.  
  329. function  WWHHelp_CookiesEnabled()
  330. {
  331.   var  bVarEnabled;
  332.  
  333.  
  334.   bVarEnabled = false;
  335.   if ((WWHFrame.WWHHelp.mSettings.mbCookies) &&
  336.       (WWHFrame.WWHBrowser.fCookiesEnabled()))
  337.   {
  338.     bVarEnabled = true;
  339.   }
  340.  
  341.   return bVarEnabled;
  342. }
  343.  
  344. function  WWHHelp_InitStage(ParamStage)
  345. {
  346.   if (( ! this.mbInitialized) &&
  347.       (ParamStage == this.mInitStage))
  348.   {
  349.     // Perform actions for current init stage
  350.     //
  351.     switch (this.mInitStage)
  352.     {
  353.       case 0:  // Start initialization process
  354.         // Alert the user if this browser is unsupported
  355.         //
  356.         if (WWHFrame.WWHBrowser.mbUnsupported)
  357.         {
  358.           alert(WWHFrame.WWHHelp.mMessages.mBrowserNotSupported);
  359.         }
  360.  
  361.         this.fReplaceLocation("WWHControlsLeftFrame", this.mHelpURLPrefix + "wwhelp/wwhimpl/common/html/init0.htm");
  362.         break;
  363.  
  364.       case 1:  // Prep book data
  365.         this.fReplaceLocation("WWHControlsLeftFrame", this.mHelpURLPrefix + "wwhelp/wwhimpl/common/html/init1.htm");
  366.         break;
  367.  
  368.       case 2:  // Load book data
  369.         this.fReplaceLocation("WWHControlsLeftFrame", this.mHelpURLPrefix + "wwhelp/wwhimpl/common/html/init2.htm");
  370.         break;
  371.  
  372.       case 3:  // Handler setup
  373.         // Initialize handler
  374.         //
  375.         WWHFrame.WWHHandler.fInit();
  376.         break;
  377.  
  378.       case 4:  // Display controls
  379.         // Preload graphics
  380.         //
  381.         WWHHelpUtilities_PreloadGraphics();
  382.  
  383.         // Initialize controls
  384.         //
  385.         WWHFrame.WWHControls.fInitialize();
  386.         break;
  387.  
  388.       case 5:  // Display document
  389.         this.fSetDocumentFrame();
  390.         this.mbInitialized = true;
  391.  
  392.         // Set frame names for accessibility
  393.         //
  394.         if (this.mbAccessible)
  395.         {
  396.           WWHFrame.WWHHelp.fSetFrameName("WWHControlsLeftFrame");
  397.           WWHFrame.WWHHelp.fSetFrameName("WWHTitleFrame");
  398.           WWHFrame.WWHHelp.fSetFrameName("WWHControlsRightFrame");
  399.           WWHFrame.WWHHelp.fSetFrameName("WWHDocumentFrame");
  400.         }
  401.  
  402.         // Finalize hander
  403.         //
  404.         WWHFrame.WWHHandler.fFinalize();
  405.         break;
  406.     }
  407.  
  408.     // Increment stage
  409.     //
  410.     this.mInitStage++;
  411.   }
  412.  
  413.   return 0;
  414. }
  415.  
  416. function  WWHHelp_HandlerInitialized()
  417. {
  418.   if (WWHFrame.WWHHelp.mInitStage > 0)
  419.   {
  420.     if (WWHFrame.WWHHandler.mbInitialized)
  421.     {
  422.       this.fReplaceLocation("WWHControlsRightFrame", this.mHelpURLPrefix + "wwhelp/wwhimpl/common/html/init3.htm");
  423.     }
  424.   }
  425. }
  426.  
  427. function  WWHHelp_GetFrameName(ParamFrameName)
  428. {
  429.   var  VarName;
  430.  
  431.  
  432.   // Determine name for this frame
  433.   //
  434.   VarName = null;
  435.   switch (ParamFrameName)
  436.   {
  437.     case "WWHFrame":
  438.       // Nothing to do
  439.       //
  440.       break;
  441.  
  442.     case "WWHNavigationFrame":
  443.       // Nothing to do
  444.       //
  445.       break;
  446.  
  447.     case "WWHTabsFrame":
  448.     case "WWHPanelFrame":
  449.     case "WWHPanelNavigationFrame":
  450.     case "WWHPanelViewFrame":
  451.       VarName = WWHFrame.WWHHandler.fGetFrameName(ParamFrameName);
  452.       break;
  453.  
  454.     case "WWHContentFrame":
  455.       // Nothing to do
  456.       //
  457.       break;
  458.  
  459.     case "WWHPageNavFrame":
  460.       // Nothing to do
  461.       //
  462.       break;
  463.  
  464.     case "WWHControlsLeftFrame":
  465.       VarName = WWHStringUtilities_EscapeHTML(WWHFrame.WWHControls.fLeftFrameTitle());
  466.       break;
  467.  
  468.     case "WWHTitleFrame":
  469.       VarName = "";
  470.       break;
  471.  
  472.     case "WWHControlsRightFrame":
  473.       VarName = WWHStringUtilities_EscapeHTML(WWHFrame.WWHControls.fRightFrameTitle());
  474.       break;
  475.  
  476.     case "WWHDocumentFrame":
  477.       VarName = WWHStringUtilities_EscapeHTML(WWHFrame.WWHHelp.mMessages.mAccessibilityDocumentFrameName);
  478.       break;
  479.   }
  480. }
  481.  
  482. function  WWHHelp_SetFrameName(ParamFrameName)
  483. {
  484.   var  VarName;
  485.   var  VarFrame;
  486.  
  487.  
  488.   if (WWHFrame.WWHBrowser.mbSupportsFrameRenaming)
  489.   {
  490.     // Get frame name
  491.     //
  492.     VarName = this.fGetFrameName(ParamFrameName);
  493.     if (VarName != null)
  494.     {
  495.       // Set frame name
  496.       //
  497.       VarFrame = eval(this.fGetFrameReference(ParamFrameName));
  498.       VarFrame.name = VarName;
  499.     }
  500.   }
  501. }
  502.  
  503. function  WWHHelp_SetDocumentFrameWithURL(ParamURL)
  504. {
  505.   var  VarURLParameters;
  506.   var  VarParts;
  507.   var  VarLocationURLNoParams;
  508.   var  VarNewLocationURL;
  509.  
  510.  
  511.   // Preserve URL parameter info
  512.   //
  513.   VarURLParameters = "";
  514.   VarParts = ParamURL.split("?");
  515.   if ((VarParts.length > 1) &&
  516.       (VarParts[1].length > 0))
  517.   {
  518.     VarURLParameters = VarParts[1];
  519.   }
  520.  
  521.   // Determine location URL
  522.   //
  523.   VarParts = this.mLocationURL.split("?");
  524.   VarLocationURLNoParams = VarParts[0];
  525.  
  526.   // Build new location URL
  527.   //
  528.   VarNewLocationURL = VarLocationURLNoParams + "?" + VarURLParameters;
  529.  
  530.   // Update location and redirect
  531.   //
  532.   this.mLocationURL = VarNewLocationURL;
  533.   this.fSetDocumentFrame();
  534. }
  535.  
  536. function  WWHHelp_SetDocumentFrame()
  537. {
  538.   var  DocumentLoaded;
  539.   var  ContextDocumentURL;
  540.   var  bVarReplace;
  541.   var  VarDocumentFrame;
  542.  
  543.  
  544.   // Preserve current document if user clicked forward or back to see it
  545.   //
  546.   if (this.mDocumentLoaded != null)
  547.   {
  548.     DocumentLoaded = this.mDocumentLoaded;
  549.  
  550.     this.mDocumentLoaded = null;
  551.     this.fUpdate(DocumentLoaded);
  552.   }
  553.   else
  554.   {
  555.     // Replace document frame if "blank.htm" currently displayed
  556.     //
  557.     bVarReplace = false;
  558.     VarDocumentFrame = eval(this.fGetFrameReference("WWHDocumentFrame"));
  559.     if (VarDocumentFrame.location.href.indexOf("wwhelp/wwhimpl/common/html/blank.htm") != -1)
  560.     {
  561.       bVarReplace = true;
  562.     }
  563.  
  564.     // Display document or determine correct document to display
  565.     //
  566.     ContextDocumentURL = this.fDetermineContextDocument();
  567.     if (ContextDocumentURL != null)
  568.     {
  569.       this.fSetDocumentHREF(ContextDocumentURL, bVarReplace);
  570.     }
  571.     else  // Load topic data to determine document to display
  572.     {
  573.       this.fSetDocumentHREF(this.mBaseURL + "wwhelp/wwhimpl/common/html/document.htm", bVarReplace);
  574.     }
  575.   }
  576. }
  577.  
  578. function  WWHHelp_SetDocumentHREF(ParamURL,
  579.                                   bParamReplace)
  580. {
  581.   var  RestoredURL;
  582.  
  583.  
  584.   if (ParamURL.length > 0)
  585.   {
  586.     RestoredURL = WWHFrame.WWHBrowser.fRestoreEscapedSpaces(ParamURL);
  587.  
  588.     if (bParamReplace)
  589.     {
  590.       this.fReplaceLocation("WWHDocumentFrame", RestoredURL);
  591.     }
  592.     else
  593.     {
  594.       this.fSetLocation("WWHDocumentFrame", RestoredURL);
  595.     }
  596.   }
  597. }
  598.  
  599. function  WWHHelp_GetBookIndexFileIndexURL(ParamBookIndex,
  600.                                            ParamFileIndex,
  601.                                            ParamAnchor)
  602. {
  603.   var  URL = "";
  604.   var  BookListEntry;
  605.  
  606.  
  607.   if ((ParamBookIndex >= 0) &&
  608.       (ParamFileIndex >= 0))
  609.   {
  610.     BookListEntry = this.mBooks.mBookList[ParamBookIndex];
  611.  
  612.     URL = this.mBaseURL + BookListEntry.mDirectory + BookListEntry.mFiles.fFileIndexToHREF(ParamFileIndex);
  613.     if ((typeof(ParamAnchor) != "undefined") &&
  614.         (ParamAnchor != null) &&
  615.         (ParamAnchor.length > 0))
  616.     {
  617.       URL += "#" + ParamAnchor;
  618.     }
  619.   }
  620.  
  621.   return URL;
  622. }
  623.  
  624. function  WWHHelp_DetermineContextDocument()
  625. {
  626.   var  ContextDocumentURL = null;
  627.   var  URLParams          = this.fGetURLParameters(this.mLocationURL);
  628.   var  ContextBook;
  629.  
  630.  
  631.   // Automatically synchronize TOC
  632.   //
  633.   this.mbAutoSyncTOC = true;
  634.  
  635.   // Check for context specification
  636.   //
  637.   if (URLParams[3] != null)  // href specified
  638.   {
  639.     ContextDocumentURL = this.mBaseURL + URLParams[3];
  640.   }
  641.   else if (URLParams[0] != null)  // context specified
  642.   {
  643.     // Determine book directory
  644.     //
  645.     ContextBook = this.mBooks.fGetContextBook(URLParams[0]);
  646.     if (ContextBook != null)
  647.     {
  648.       if (URLParams[2] != null)  // file specified
  649.       {
  650.         ContextDocumentURL = this.mBaseURL + ContextBook.mDirectory + URLParams[2];
  651.       }
  652.       else if (URLParams[1] != null)  // topic specified
  653.       {
  654.         // Setup for a topic search
  655.         //
  656.         this.mContextDir = ContextBook.mDirectory;
  657.         this.mTopicTag   = URLParams[1];
  658.  
  659.         this.mDocumentURL = "";
  660.       }
  661.     }
  662.     else  // Display splash page if nothing else found
  663.     {
  664.       ContextDocumentURL = this.mBaseURL + "wwhelp/wwhimpl/common/html/default.htm";
  665.     }
  666.   }
  667.   else  // Display splash page if nothing else found
  668.   {
  669.     ContextDocumentURL = this.mBaseURL + "wwhelp/wwhimpl/common/html/default.htm";
  670.   }
  671.  
  672.   return ContextDocumentURL;
  673. }
  674.  
  675. function  WWHHelp_LoadTopicData()
  676. {
  677.   var  LoadTopicDataHTML = "";
  678.  
  679.  
  680.   LoadTopicDataHTML += "<script type=\"text/javascript\" language=\"JavaScript1.2\" src=\"" + this.mHelpURLPrefix + WWHFrame.WWHBrowser.fRestoreEscapedSpaces(this.mContextDir) + "wwhdata/common/topics.js\"></script>";
  681.   LoadTopicDataHTML += "<script type=\"text/javascript\" language=\"JavaScript1.2\" src=\"" + this.mHelpURLPrefix + "wwhelp/wwhimpl/common/scripts/documt1s.js\"></script>";
  682.  
  683.   return LoadTopicDataHTML;
  684. }
  685.  
  686. function  WWHHelp_ProcessTopicResult(ParamTopicURL)
  687. {
  688.   if (ParamTopicURL != null)
  689.   {
  690.     this.mDocumentURL = this.mBaseURL + this.mContextDir + ParamTopicURL;
  691.   }
  692. }
  693.  
  694. function  WWHHelp_DisplayContextDocument()
  695. {
  696.   WWHFrame.WWHHelp.fSetDocumentHREF(this.mDocumentURL, true);
  697. }
  698.  
  699. function  WWHHelp_GetURLPrefix(ParamURL)
  700. {
  701.   var  URLPrefix  = null;
  702.   var  WorkingURL = "";
  703.   var  Parts;
  704.   var  Index;
  705.  
  706.  
  707.   // Standardize URL for processing
  708.   //
  709.   WorkingURL = ParamURL;
  710.  
  711.   // Strip any URL parameters
  712.   //
  713.   if (WorkingURL.indexOf("?") != -1)
  714.   {
  715.     Parts = WorkingURL.split("?");
  716.     WorkingURL = Parts[0];
  717.   }
  718.  
  719.   // Confirm URL in wwhelp hierarchy
  720.   //
  721.   if (((Index = WorkingURL.indexOf("/wwhelp/wwhimpl/api.htm")) != -1) ||
  722.       ((Index = WorkingURL.indexOf("/wwhelp/wwhimpl/common/html/switch.htm")) != -1) ||
  723.       ((Index = WorkingURL.indexOf("/wwhelp/wwhimpl/common/html/wwhelp.htm")) != -1) ||
  724.       ((Index = WorkingURL.indexOf("/wwhelp/wwhimpl/java/html/wwhelp.htm"))   != -1) ||
  725.       ((Index = WorkingURL.indexOf("/wwhelp/wwhimpl/js/html/wwhelp.htm"))     != -1))
  726.   {
  727.     URLPrefix = WorkingURL.substring(0, Index);
  728.   }
  729.   else
  730.   {
  731.     // Look for match on top level "wwhelp.htm" file
  732.     //
  733.     Index = WorkingURL.lastIndexOf("/");
  734.     if ((Index != -1) &&
  735.        (Index == WorkingURL.indexOf("/wwhelp.htm")))
  736.     {
  737.       URLPrefix = WorkingURL.substring(0, Index);
  738.     }
  739.   }
  740.  
  741.   return URLPrefix;
  742. }
  743.  
  744. function  WWHHelp_SetContextDocument(ParamURL)
  745. {
  746.   var  URL = WWHFrame.WWHBrowser.fNormalizeURL(ParamURL);
  747.   var  CurrentURLPrefix;
  748.   var  NewURLPrefix;
  749.   var  VarDocumentFrame;
  750.   var  VarDocumentURL;
  751.  
  752.  
  753.   // Confirm URL under same hierarchy
  754.   //
  755.   CurrentURLPrefix = WWHHelp_GetURLPrefix(this.mLocationURL);
  756.   NewURLPrefix     = WWHHelp_GetURLPrefix(URL);
  757.   if ((CurrentURLPrefix != null) &&
  758.       (NewURLPrefix     != null) &&
  759.       (CurrentURLPrefix == NewURLPrefix))
  760.   {
  761.     // Automatically synchornize TOC
  762.     //
  763.     this.mbAutoSyncTOC = true;
  764.  
  765.     // Check if in single topic mode
  766.     //
  767.     if (this.fSingleTopic())
  768.     {
  769.       // Check for required switch to frameset with navigation
  770.       //
  771.       WWHFrame.WWHSwitch.fProcessURL(ParamURL);
  772.       if (WWHFrame.WWHSwitch.mImplementation != "single")
  773.       {
  774.         // Switch to frameset with navigation
  775.         //
  776.         if (WWHFrame.WWHSwitch.mParameters.length > 0)
  777.         {
  778.           // Context and topic supplied, use them
  779.           //
  780.           this.fSetLocation("WWHFrame", ParamURL);
  781.         }
  782.         else
  783.         {
  784.           // Just switch to frameset with navigation and preserve the current document
  785.           //
  786.           VarDocumentFrame = eval(this.fGetFrameReference("WWHDocumentFrame"));
  787.  
  788.           VarDocumentURL = WWHFrame.WWHBrowser.fNormalizeURL(VarDocumentFrame.location.href);
  789.           VarDocumentURL = WWHFrame.WWHHelp.fGetBookFileHREF(VarDocumentURL);
  790.           WWHFrame.WWHSwitch.fExec(false, WWHFrame.WWHHelp.mHelpURLPrefix + "/wwhelp/wwhimpl/common/html/wwhelp.htm?href=" + WWHFrame.WWHBrowser.fRestoreEscapedSpaces(VarDocumentURL));
  791.         }
  792.       }
  793.       else
  794.       {
  795.         // Update document frame
  796.         //
  797.         this.fSetDocumentFrameWithURL(URL);
  798.       }
  799.     }
  800.     else
  801.     {
  802.       // Update document frame
  803.       //
  804.       this.fSetDocumentFrameWithURL(URL);
  805.     }
  806.   }
  807.   else
  808.   {
  809.     // Some other help system requested, redirect to it
  810.     //
  811.     this.fSetLocation("WWHFrame", ParamURL);
  812.   }
  813. }
  814.  
  815. function  WWHHelp_GetBookFileHREF(ParamHREF)
  816. {
  817.   var  BookFileHREF = null;
  818.   var  Prefix;
  819.   var  Suffix;
  820.  
  821.  
  822.   // Confirm HREF can be in same hierarchy as BaseURL
  823.   //
  824.   if ((this.mBaseURL.length > 0) &&
  825.       (ParamHREF.length > this.mBaseURL.length))
  826.   {
  827.     Prefix = ParamHREF.substring(0, this.mBaseURL.length);
  828.     Suffix = ParamHREF.substring(this.mBaseURL.length, ParamHREF.length);
  829.  
  830.     // Confirm HREF definitely is in same hierarchy as BaseURL
  831.     //
  832.     if (Prefix == this.mBaseURL)
  833.     {
  834.       BookFileHREF = Suffix;
  835.     }
  836.   }
  837.  
  838.   return BookFileHREF;
  839. }
  840.  
  841. function  WWHHelp_HREFToBookIndexFileIndexAnchor(ParamHREF)
  842. {
  843.   var  ResultArray = new Array(-1, -1, "");
  844.   var  BookFileHREF;
  845.  
  846.  
  847.   BookFileHREF = this.fGetBookFileHREF(ParamHREF);
  848.   if (BookFileHREF != null)
  849.   {
  850.     ResultArray = this.mBooks.fHREFToBookIndexFileIndexAnchor(BookFileHREF);
  851.   }
  852.  
  853.   return ResultArray;
  854. }
  855.  
  856. function  WWHHelp_GetSyncPrevNext(ParamHREF)
  857. {
  858.   var  ResultArray = new Array(null, null, null);
  859.   var  Parts;
  860.   var  AbsoluteHREF;
  861.   var  VarAnchor;
  862.   var  BookFileHREF;
  863.  
  864.  
  865.   // Trim named anchor entries
  866.   //
  867.   Parts = ParamHREF.split("#");
  868.   AbsoluteHREF = Parts[0];
  869.   VarAnchor = "";
  870.   if (Parts.length > 1)
  871.   {
  872.     if (Parts[1].length > 0)
  873.     {
  874.       VarAnchor = "#" + Parts[1];
  875.     }
  876.   }
  877.  
  878.   BookFileHREF = this.fGetBookFileHREF(AbsoluteHREF);
  879.   if (BookFileHREF != null)
  880.   {
  881.     if (BookFileHREF == "wwhelp/wwhimpl/common/html/default.htm")
  882.     {
  883.       ResultArray[2] = this.mBooks.fBookFileIndiciesToHREF(0, 0);
  884.     }
  885.     else
  886.     {
  887.       ResultArray = this.mBooks.fGetSyncPrevNext(BookFileHREF);
  888.     }
  889.  
  890.     // Prefix with BaseURL if defined
  891.     //
  892.  
  893.     // Current
  894.     //
  895.     if (ResultArray[0] != null)
  896.     {
  897.       ResultArray[0] = this.mBaseURL + ResultArray[0] + VarAnchor;
  898.     }
  899.  
  900.     // Previous
  901.     //
  902.     if (ResultArray[1] != null)
  903.     {
  904.       ResultArray[1] = this.mBaseURL + ResultArray[1];
  905.     }
  906.  
  907.     // Next
  908.     //
  909.     if (ResultArray[2] != null)
  910.     {
  911.       ResultArray[2] = this.mBaseURL + ResultArray[2];
  912.     }
  913.   }
  914.   else
  915.   {
  916.     // Unknown document, enable next button to go to first known page
  917.     //
  918.     ResultArray[2] = this.mBaseURL + this.mBooks.fBookFileIndiciesToHREF(0, 0);
  919.   }
  920.  
  921.   return ResultArray;
  922. }
  923.  
  924. function  WWHHelp_HREFToTitle(ParamHREF)
  925. {
  926.   var  Title;
  927.   var  Parts;
  928.   var  AbsoluteHREF;
  929.  
  930.  
  931.   // Try to find book and file
  932.   //
  933.   Parts = this.fHREFToBookIndexFileIndexAnchor(ParamHREF);
  934.   if ((Parts[0] >= 0) &&
  935.       (Parts[1] >= 0))
  936.   {
  937.     Title = this.mBooks.fBookIndexFileIndexToTitle(Parts[0], Parts[1]);
  938.   }
  939.   else
  940.   {
  941.     // Use basename for title
  942.     //
  943.     Parts = ParamHREF.split("#");
  944.     AbsoluteHREF = Parts[0];
  945.     Parts = AbsoluteHREF.split("/");
  946.     Title = Parts[Parts.length - 1];
  947.   }
  948.  
  949.   return Title;
  950. }
  951.  
  952. function  WWHHelp_PopupHTML()
  953. {
  954.   var  VarHTML = "";
  955.  
  956.  
  957.   if (WWHFrame.WWHBrowser.mbSupportsPopups)
  958.   {
  959.     VarHTML = this.mPopup.fDivTagText();
  960.   }
  961.  
  962.   return VarHTML;
  963. }
  964.  
  965. function  WWHHelp_ShowPopup(ParamContext,
  966.                             ParamLink,
  967.                             ParamEvent)
  968. {
  969.   var  PopupHTML;
  970.  
  971.  
  972.   if (WWHFrame.WWHBrowser.mbSupportsPopups)
  973.   {
  974.     PopupHTML = this.mBooks.fGetPopupHTML(ParamContext, ParamLink);
  975.     if ((PopupHTML != null) &&
  976.         (PopupHTML.length > 0))
  977.     {
  978.       this.mPopup.fShow(PopupHTML, ParamEvent);
  979.     }
  980.   }
  981. }
  982.  
  983. function  WWHHelp_HidePopup()
  984. {
  985.   this.mPopup.fHide();
  986. }
  987.  
  988. function  WWHHelp_ClickedPopup(ParamContext,
  989.                                ParamLink)
  990. {
  991.   var  PopupLink;
  992.   var  PopupHTML;
  993.  
  994.  
  995.   PopupLink = WWHFrame.WWHBrowser.fRestoreEscapedSpaces(ParamLink);
  996.   if (WWHFrame.WWHBrowser.mbSupportsPopups)
  997.   {
  998.     this.fGotoPopupTarget(ParamContext, PopupLink);
  999.   }
  1000.   else
  1001.   {
  1002.     // Confirm popup text exists to be displayed
  1003.     //
  1004.     PopupHTML = this.mBooks.fGetPopupHTML(ParamContext, PopupLink);
  1005.     if ((PopupHTML != null) &&
  1006.         (PopupHTML.length > 0))
  1007.     {
  1008.       // Record popup information
  1009.       //
  1010.       this.mPopupContext = ParamContext;
  1011.       this.mPopupLink    = PopupLink;
  1012.  
  1013.       // Display popup in browser window
  1014.       //
  1015.       WWHFrame.WWHHelp.fSetDocumentHREF(this.mBaseURL + "wwhelp/wwhimpl/common/html/popup.htm", false);
  1016.     }
  1017.     else
  1018.     {
  1019.       this.fGotoPopupTarget(ParamContext, PopupLink);
  1020.     }
  1021.   }
  1022. }
  1023.  
  1024. function  WWHHelp_GotoPopupTarget(ParamContext,
  1025.                                   ParamLink)
  1026. {
  1027.   var  Link = WWHFrame.WWHBrowser.fNormalizeURL(ParamLink);
  1028.   var  LinkHREF = null;
  1029.   var  Book;
  1030.  
  1031.  
  1032.   Book = this.mBooks.fGetContextBook(ParamContext);
  1033.   if (Book != null)
  1034.   {
  1035.     // Clickable popup?
  1036.     //
  1037.     if (Book.mPopups.fIsPopupClickable(ParamLink))
  1038.     {
  1039.       // Hide the popup if it is visible
  1040.       //
  1041.       this.fHidePopup();
  1042.  
  1043.       WWHFrame.WWHHelp.fSetDocumentHREF(this.mBaseURL + Book.mDirectory + Link, false);
  1044.     }
  1045.   }
  1046. }
  1047.  
  1048. function  WWHHelp_GetPopupAccessibleHTML()
  1049. {
  1050.   var  HTML = "";
  1051.   var  Book;
  1052.  
  1053.  
  1054.   // Get popup HTML
  1055.   //
  1056.   HTML = this.mBooks.fGetPopupHTML(this.mPopupContext, this.mPopupLink);
  1057.   if (HTML == null)
  1058.   {
  1059.     HTML = "";
  1060.   }
  1061.  
  1062.   // Clickable popup?
  1063.   //
  1064.   Book = this.mBooks.fGetContextBook(this.mPopupContext);
  1065.   if (Book != null)
  1066.   {
  1067.     if (Book.mPopups.fIsPopupClickable(this.mPopupLink))
  1068.     {
  1069.       // Display a link to the original document
  1070.       //
  1071.       HTML += "<p>";
  1072.       HTML += "<a href=\"javascript:WWHFrame.WWHHelp.fGotoPopupTarget('" + WWHStringUtilities_EscapeURLForJavaScriptAnchor(this.mPopupContext) + "', '" + WWHStringUtilities_EscapeURLForJavaScriptAnchor(this.mPopupLink) + "');\">";
  1073.       HTML += WWHStringUtilities_EscapeHTML(WWHFrame.WWHHelp.mMessages.mAccessibilityPopupClickThrough);
  1074.       HTML += "</a>";
  1075.       HTML += "</p>";
  1076.     }
  1077.   }
  1078.  
  1079.   return HTML;
  1080. }
  1081.  
  1082. function  WWHHelp_DisplayFirst()
  1083. {
  1084.   VarURL = WWHFrame.WWHHelp.fGetBookIndexFileIndexURL(0, 0, null);
  1085.   WWHFrame.WWHHelp.fSetDocumentHREF(VarURL, true);
  1086.  
  1087.   // Automatically synchronize TOC
  1088.   //
  1089.   this.mbAutoSyncTOC = true;
  1090. }
  1091.  
  1092. function  WWHHelp_Update(ParamURL)
  1093. {
  1094.   var  URL;
  1095.   var  Parts;
  1096.  
  1097.  
  1098.   if (this.mbInitialized)
  1099.   {
  1100.     URL = WWHFrame.WWHBrowser.fNormalizeURL(ParamURL);
  1101.  
  1102.     if (WWHFrame.WWHHandler.fIsReady())
  1103.     {
  1104.       Parts = this.fHREFToBookIndexFileIndexAnchor(URL);
  1105.       if ((Parts[0] >= 0) &&
  1106.           (Parts[1] >= 0))
  1107.       {
  1108.         WWHFrame.WWHHandler.fUpdate(Parts[0], Parts[1], Parts[2]);
  1109.       }
  1110.     }
  1111.  
  1112.     this.fDocumentBookkeeping(URL);
  1113.   }
  1114.   else if (ParamURL.indexOf("wwhelp/wwhimpl/common/html/default.htm") == -1)
  1115.   {
  1116.     this.mDocumentLoaded = ParamURL;
  1117.   }
  1118. }
  1119.  
  1120. function  WWHHelp_SyncTOC(ParamURL)
  1121. {
  1122.   var  Parts;
  1123.  
  1124.  
  1125.   if (WWHFrame.WWHHandler.fIsReady())
  1126.   {
  1127.     Parts = this.fHREFToBookIndexFileIndexAnchor(ParamURL);
  1128.     if ((Parts[0] >= 0) &&
  1129.         (Parts[1] >= 0))
  1130.     {
  1131.       WWHFrame.WWHHandler.fSyncTOC(Parts[0], Parts[1], Parts[2]);
  1132.     }
  1133.   }
  1134. }
  1135.  
  1136. function  WWHHelp_DocumentBookkeeping(ParamURL)
  1137. {
  1138.   // Highlight search words
  1139.   //
  1140.   if (typeof(WWHFrame.WWHHighlightWords) != "undefined")
  1141.   {
  1142.     WWHFrame.WWHHighlightWords.fExec();
  1143.   }
  1144.  
  1145.   // Update controls
  1146.   //
  1147.   WWHFrame.WWHControls.fUpdateHREF(ParamURL);
  1148.  
  1149.   // Update window title, if possible
  1150.   //
  1151.   if (ParamURL.indexOf("wwhelp/wwhimpl/common/html/default.htm") == -1)
  1152.   {
  1153.     if (WWHFrame.WWHBrowser.mBrowser != 1)  // Shorthand for Netscape
  1154.     {
  1155.       WWHFrame.document.title = WWHStringUtilities_UnescapeHTML(this.fHREFToTitle(ParamURL));
  1156.     }
  1157.   }
  1158.  
  1159.   // Automatically synchronize TOC, if requested
  1160.   //
  1161.   if (this.mbAutoSyncTOC)
  1162.   {
  1163.     if ( ! WWHFrame.WWHHelp.fSingleTopic())
  1164.     {
  1165.       WWHFrame.WWHControls.fSyncTOC();
  1166.     }
  1167.  
  1168.     this.mbAutoSyncTOC = false;
  1169.   }
  1170. }
  1171.  
  1172. function  WWHHelp_Unload()
  1173. {
  1174.   // Clear related topics list
  1175.   //
  1176.   WWHFrame.WWHRelatedTopics.fClear();
  1177. }
  1178.  
  1179. function  WWHHelp_IgnoreNextKeyPress(ParamEvent)
  1180. {
  1181.   if (this.mbInitialized)
  1182.   {
  1183.     if ((ParamEvent != null) &&
  1184.         (typeof(ParamEvent.keyCode) != "undefined"))
  1185.     {
  1186.       this.mbIgnoreNextKeyPress = true;
  1187.     }
  1188.   }
  1189.  
  1190.   return true;
  1191. }
  1192.  
  1193. function  WWHHelp_HandleKeyDown(ParamEvent)
  1194. {
  1195.   if (this.mbInitialized)
  1196.   {
  1197.     if ((ParamEvent != null) &&
  1198.         (typeof(ParamEvent.keyCode) != "undefined"))
  1199.     {
  1200.       if (ParamEvent.keyCode == 18)
  1201.       {
  1202.         this.mbAltKeyDown = true;
  1203.       }
  1204.       else if ((ParamEvent.keyCode >= 48) &&
  1205.                (ParamEvent.keyCode <= 57))
  1206.       {
  1207.         this.mAccessKey = ParamEvent.keyCode - 48;
  1208.       }
  1209.     }
  1210.   }
  1211.  
  1212.   return true;
  1213. }
  1214.  
  1215. function  WWHHelp_HandleKeyPress(ParamEvent)
  1216. {
  1217.   if (this.mbInitialized)
  1218.   {
  1219.     if (ParamEvent != null)
  1220.     {
  1221.       if (this.mbIgnoreNextKeyPress)
  1222.       {
  1223.         // Ignore this key press event
  1224.         //
  1225.       }
  1226.       else
  1227.       {
  1228.         if (this.mAccessKey != null)
  1229.         {
  1230.           this.fProcessAccessKey(this.mAccessKey);
  1231.         }
  1232.       }
  1233.     }
  1234.  
  1235.     // Reset to handle next access key
  1236.     //
  1237.     this.mbIgnoreNextKeyPress = false;
  1238.     this.mAccessKey = null;
  1239.   }
  1240.  
  1241.   return true;
  1242. }
  1243.  
  1244. function  WWHHelp_HandleKeyUp(ParamEvent)
  1245. {
  1246.   if (this.mbInitialized)
  1247.   {
  1248.     if ((ParamEvent != null) &&
  1249.         (typeof(ParamEvent.keyCode) != "undefined"))
  1250.     {
  1251.       if (ParamEvent.keyCode == 18)
  1252.       {
  1253.         this.mbAltKeyDown = false;
  1254.       }
  1255.     }
  1256.   }
  1257.  
  1258.   return true;
  1259. }
  1260.  
  1261. function  WWHHelp_ProcessAccessKey(ParamAccessKey)
  1262. {
  1263.   switch (ParamAccessKey)
  1264.   {
  1265.     case 1:
  1266.     case 2:
  1267.     case 3:
  1268.       WWHFrame.WWHHandler.fProcessAccessKey(ParamAccessKey);
  1269.       break;
  1270.  
  1271.     case 4:
  1272.     case 5:
  1273.     case 6:
  1274.     case 7:
  1275.     case 8:
  1276.     case 9:
  1277.       WWHFrame.WWHControls.fProcessAccessKey(ParamAccessKey);
  1278.       break;
  1279.  
  1280.     case 0:
  1281.       this.fFocus("WWHDocumentFrame");
  1282.       break;
  1283.   }
  1284. }
  1285.  
  1286. function  WWHHelp_Focus(ParamFrameName,
  1287.                         ParamAnchorName)
  1288. {
  1289.   WWHFrame.WWHBrowser.fFocus(this.fGetFrameReference(ParamFrameName), ParamAnchorName);
  1290. }
  1291.  
  1292. function  WWHHelpUtilities_PreloadGraphics()
  1293. {
  1294.   var  VarImageDirectory = WWHFrame.WWHHelp.mHelpURLPrefix + "wwhelp/wwhimpl/common/images";
  1295.   var  VarImage = new Image();
  1296.  
  1297.  
  1298.   VarImage.src = VarImageDirectory + "/bkmark.gif";
  1299.   VarImage.src = VarImageDirectory + "/bkmarkx.gif";
  1300.   VarImage.src = VarImageDirectory + "/close.gif";
  1301.   VarImage.src = VarImageDirectory + "/divider.gif";
  1302.   VarImage.src = VarImageDirectory + "/doc.gif";
  1303.   VarImage.src = VarImageDirectory + "/email.gif";
  1304.   VarImage.src = VarImageDirectory + "/emailx.gif";
  1305.   VarImage.src = VarImageDirectory + "/fc.gif";
  1306.   VarImage.src = VarImageDirectory + "/fo.gif";
  1307.   VarImage.src = VarImageDirectory + "/frameset.gif";
  1308.   VarImage.src = VarImageDirectory + "/next.gif";
  1309.   VarImage.src = VarImageDirectory + "/nextx.gif";
  1310.   VarImage.src = VarImageDirectory + "/prev.gif";
  1311.   VarImage.src = VarImageDirectory + "/prevx.gif";
  1312.   VarImage.src = VarImageDirectory + "/print.gif";
  1313.   VarImage.src = VarImageDirectory + "/printx.gif";
  1314.   VarImage.src = VarImageDirectory + "/related.gif";
  1315.   VarImage.src = VarImageDirectory + "/relatedi.gif";
  1316.   VarImage.src = VarImageDirectory + "/relatedx.gif";
  1317.   VarImage.src = VarImageDirectory + "/spacer4.gif";
  1318.   VarImage.src = VarImageDirectory + "/spc1w2h.gif";
  1319.   VarImage.src = VarImageDirectory + "/spc1w7h.gif";
  1320.   VarImage.src = VarImageDirectory + "/spc2w1h.gif";
  1321.   VarImage.src = VarImageDirectory + "/spc5w1h.gif";
  1322.   VarImage.src = VarImageDirectory + "/sync.gif";
  1323.   VarImage.src = VarImageDirectory + "/syncx.gif";
  1324. }
  1325.