/*
* This script contains Javascript that will define the menu trees for all pages
* that are part of the BSM Development site, so that they have a standard look
* and feel.
*/

/*****************************************************************************/

// Block menu type, colors, alignment, etc.
var BkMenuVertAlign = 'top';

var BkMenuColorOff = '#9999FF,#9999FF';
var BkMenuColorSel = '#9999FF,#9999FF';

var BkMenuTextAlign = 'center';
var BkMenuTextPadTop = 2;
var BkMenuTextColorOff = 'white,white';
var BkMenuTextColorSel = 'red,red';

var BkMenuFontSize = 9;

var BkMenuArrows =
  [ 'BlockArrow_White_right.gif', '', 'BlockArrow_White_left.gif' ];

// Text menu colors, font, spacing, etc.
var TxMenuArrow = '';

var TxMenuFont = 'LeftMenuText';
var TxMenuFontSize = 12;

var LeftSubmenuFont = 'LeftSubmenuText';
var LeftSubmenuFontSize = 10;

var TxMenuRules = 1;
var TxMenuRuleAttr = 'border-collapse: collapse; border: 1px solid #FFFFFF;';
var TxMenuRuleOffset = 0;

var TxMenuSpacing = 18;
var TxMenuRuleSpacing = 16;
var LeftSubmenuIndent = 0;
var LeftSubmenuSpacing = 5;

var TxMenuWidth;                        // Will be set by PageHeader.js
/*
* Definition of the menu tree.
*
* All of the menu trees consist of arrays of elements that, themselves, contain
* four elements.  These look as follows:
*
*      MenuText, MenuImage, SubMenu, LinkToURL
*
* Within each of these parameters, special flags can be set and/or lists can be
* used to build a menu with additional (above the ordinary) properties.  Also,
* the first element of any submenu contains a description of the submenu, as
* follows:
*
*      MenuType, Position, Size, Parms
*
* See the documentation for BlockMenus.js for more details.
*
* Oh, and incidentally, there are no forward references in this boat-anchor
* programming language so the trees must be built from the bottom up.  That's
* life.
*/

// Submenu for case histories.
var CaseHistoryMenu =
  [
  ['', '', '0,125', 'TextAlign=left,TextPadLeft=5'],
  ['License Manager', '', 0, '/About/CaseLicense.html'],
  ['Version Control', '', 0, '/About/CaseVersion.html'],
  ['Document Manager', '', 0, '/About/CaseDocument.html'],
  ['Online Tax Bills', '', 0, '/About/CaseTaxBill.html']
  ];

// Submenu for about.
var AboutMenu =
  [
  ['', '', '0,125', 'TextAlign=left,TextPadLeft=5'],
  ['Press Releases', '', 0,
    '/cgi-bin/InsertDocList.cgi?Type=PR&TplURL=About/PressRel.html'],
  ['Case Histories', '', CaseHistoryMenu, '/About/CaseHist.html'],
  ['Testimonials', '', 0, '/About/Testimony.html'],
  ['Client List', '', 0, '/About/ClientList.html'],
  ['Our Name', '', 0, '/About/OurName.html']
  ];

// Submenu for consulting.
var ConsultingMenu =
  [
  ['', '', '0,135', 'TextAlign=left,TextPadLeft=5'],
  ['Design Services', '', 0, '/Services/Design.html'],
  ['System Evaluation', '', 0, '/Services/SystemEval.html'],
  ['Security Consulting', '', 0, '/Services/SecurityCons.html'],
  ['Freeware Evaluation', '', 0, '/Services/Freeware.html'],
  ['Recent Projects', '', 0,
    '/cgi-bin/InsertDocList.cgi?Type=Note&TplURL=Services/RecentProj.html']
  ];

// Submenu for product development.
var ProductDevelopMenu =
  [
  ['', '', '0,135', 'PageBreak=4,TextAlign=left,TextPadLeft=5'],
  ['Web Applications', '', 0, '/Services/WebDesign.html'],
  ['Database Applications', '', 0, '/Services/DatabaseApps.html'],
  ['Telephony Applications', '', 0, '/Services/TelephonyApps.html'],
  ['Turnkey Software', '', 0, '/Services/TurnkeyDevel.html'],
  ['Networked Software', '', 0, '/Services/NetworkSW.html'],
  ['System Control Software', '', 0, '/Services/ControlSys.html'],
  ['Porting Services', '', 0, '/Services/Porting.html']
  ];

// Submenu for installation.
var InstallationMenu =
  [
  ['', '', '0,135', 'TextAlign=left,TextPadLeft=5'],
  ['Physical Plant', '', 0, '/Services/PhysPlant.html'],
  ['Telephone Systems', '', 0, '/Services/Telephone.html'],
  ['System Specification', '', 0, '/Services/SystemSC.html'],
  ['OS Installation', '', 0, '/Services/OSInstall.html'],
  ['Package Installation', '', 0, '/Services/PkgInstall.html'],
  ['Quiet Systems', '', 0, '/Services/QuietSys.html']
  ];

// Submenu for services.
var ServicesMenu =
  [
  ['', '', '0,150', 'TextAlign=left,TextPadLeft=5'],
  ['Consulting Services', '', ConsultingMenu,
    '/Services/Consulting.html'],
  ['Product Development', '', ProductDevelopMenu,
    '/Services/ProductDevel.html'],
  ['Installation', '', InstallationMenu, '/Services/Installation.html'],
  ['Rates', '', 0, '/Services/Rates.html']
  ];

// Submenu for MailCorral.
var MailCorralMenu =
  [
  ['', '', '0,115', 'TextAlign=left,TextPadLeft=5'],
  ['Features', '', 0, '/MailCorral/Features.html'],
  ['Filtered Items', '', 0, '/MailCorral/Filtered.html'],
  ['Requirements', '', 0, '/MailCorral/Requirements.html'],
  ['How It Works', '', 0, '/MailCorral/HowItWorks.html'],
  ['Documentation', '', 0, '/Reference/DocIdx_MailCorral.html'],
  ['FAQ', '', 0, '/Reference/DocIdx_MailCorralFAQ.html'],
  ['Downloads', '', 0,
    '/cgi-bin/InsertDLStats.cgi?TplURL=MailCorral/Downloads.html']
  ];

// Submenu for SpamCorral.
var SpamCorralMenu =
  [
  ['', '', '0,140', 'TextAlign=left,TextPadLeft=5'],
  ['Documentation', '', 0, '/Reference/DocIdx_SpamCorral.html'],
  ['Downloads', '', 0,
    '/cgi-bin/InsertDLStats.cgi?TplURL=Products/SpamCorralDL.html']
  ];

// Submenu for the mail redirector.
var RedirectorMenu =
  [
  ['', '', '0,140', 'TextAlign=left,TextPadLeft=5'],
  ['Downloads', '', 0,
    '/cgi-bin/InsertDLStats.cgi?TplURL=Products/RedirectorDL.html']
  ];

// Submenu for the validation suite.
var VSuiteMenu =
  [
  ['', '', '0,140', 'TextAlign=left,TextPadLeft=5'],
  ['Downloads', '', 0,
    '/cgi-bin/InsertDLStats.cgi?TplURL=Products/VSuiteDL.html'],
  ['Submit Sample Virus/Spam', '', 0, '/Products/VSuiteSubmit.html']
  ];

// Submenu for Products.
var ProductsMenu =
  [
  ['', '', '0,145', 'TextAlign=left,TextPadLeft=5'],
  ['MailCorral', '', MailCorralMenu, '/MailCorral/index.html'],
  ['SpamCorral', '', SpamCorralMenu, '/Products/SpamCorral.html'],
  ['Mail Redirector', '', RedirectorMenu, '/Products/Redirector.html'],
  ['Mail Validation Suite', '', VSuiteMenu, '/Products/VSuite.html'],
  ['Downloads', '', 0,
    '/cgi-bin/InsertDLStats.cgi?TplURL=Products/Downloads.html'],
  ['Contributions', '', 0, '/Products/Contribute.html']
  ];

// Submenu for Reference.
var ReferenceMenu =
  [
  ['', '', '0,135', 'TextAlign=left,TextPadLeft=5'],
  ['Documentation', '', 0,
    '/cgi-bin/InsertDocList.cgi?Type=Doc&TplURL=Reference/Documentation.html'],
  ['Installation Notes', '', 0,
    '/cgi-bin/InsertDocList.cgi?Type=Doc&TplURL=Reference/Notes.html'],
  ['Tech Notes', '', 0,
    '/cgi-bin/InsertDocList.cgi?Type=Doc&TplURL=Reference/TechNotes.html'],
  ['Sample Code', '', 0,
    '/cgi-bin/InsertDocList.cgi?Type=Doc&TplURL=Reference/Samples.html']
  ];

// Submenu for Resources.
var ResourcesMenu =
  [
  ['', '', '0,135', 'TextAlign=left,TextPadLeft=5'],
  ['Links', '', 0, '/Resources/Links.html'],
  ['Products We Use', '', 0, '/Resources/ProdUse.html'],
  ['Partners', '', 0, '/Resources/Partners.html']
  ];

// Bar menu across top of page.
var BarMenu =
  [
  ['image=/Menu/AboutMenu_norm.gif,/Menu/AboutMenu_roll.gif',
    '', AboutMenu, '/About/index.html'],
  ['image=/Menu/ServicesMenu_norm.gif,/Menu/ServicesMenu_roll.gif',
    '', ServicesMenu, '/Services/index.html'],
  ['image=/Menu/ProductsMenu_norm.gif,/Menu/ProductsMenu_roll.gif',
    '', ProductsMenu, '/Products/index.html'],
  ['image=/Menu/ReferenceMenu_norm.gif,/Menu/ReferenceMenu_roll.gif',
    '', ReferenceMenu, '/Reference/index.html'],
  ['image=/Menu/ResourcesMenu_norm.gif,/Menu/ResourcesMenu_roll.gif',
    '', ResourcesMenu, '/Resources/index.html'],
  ['image=/Menu/SearchMenu_norm.gif,/Menu/SearchMenu_roll.gif',
    '', 0, '/cgi-bin/LoadDynamic.cgi?DynAddr=jump-gate&DynURL=http://Search.html']
  ];

// Page menu across the bottom of the page.
//
// The entire menu tree that is used for the bar menu is reused here, except
// for the top level.  At the top level, we have added an extra item for the
// home page, so that the user can get back to it, if they really have to, and
// the contact page.  Also, the search menu item is dropped.
var PageMenu =
  [
  ['Home', '', 0, '/index.html'],
  ['About Us', '', AboutMenu, '/About/index.html'],
  ['Services', '', ServicesMenu, '/Services/index.html'],
  ['Products', '', ProductsMenu, '/Products/index.html'],
  ['Reference', '', ReferenceMenu, '/Reference/index.html'],
  ['Resources', '', ResourcesMenu, '/Resources/index.html'],
  ['Search', '', 0,
    '/cgi-bin/LoadDynamic.cgi?DynAddr=jump-gate&DynURL=http://Search.html'],
  ['Contact Us', '', 0, '/About/index.html#ContactUs']
  ];

// Bingo buttons to the right of the page (actually displayed in
// PageFooter.js).
var BingoButtons =
  [
  ['Our Rates', '/Services/Rates.html'],
  ['Client List', '/About/ClientList.html'],
  ['Case Histories', '/About/CaseHist.html'],
  ['Documentation',
    '/cgi-bin/InsertDocList.cgi?Type=Doc&TplURL=Reference/Documentation.html'],
  ['Tech Notes',
    '/cgi-bin/InsertDocList.cgi?Type=Doc&TplURL=Reference/TechNotes.html'],
  ['Downloads',
    '/cgi-bin/InsertDLStats.cgi?TplURL=Products/Downloads.html'],
  ['Contact Us', '/About/index.html#ContactUs']
  ];

// Selectors used for the page menu by the various pages within the site.
// These are, in essence, menu paths.
var PageHome = '1';

var PageAbout = '2';
var PageAboutPressReleases = '2.1';
var PageAboutPressRelItem = '2.1.1';
var PageAboutCaseHistories = '2.2';
var PageAboutCaseHistLicense = '2.2.1';
var PageAboutCaseHistVersion = '2.2.2';
var PageAboutCaseHistDocManager = '2.2.3';
var PageAboutCaseHistTaxBill = '2.2.4';
var PageAboutTestimonials = '2.3';
var PageAboutClientList = '2.4';
var PageAboutOurName = '2.5';

var PageServices = '3';
var PageServicesConsulting = '3.1';
var PageServicesConsDesign = '3.1.1';
var PageServicesConsEvaluation = '3.1.2';
var PageServicesConsSecurity = '3.1.3';
var PageServicesConsFreeware = '3.1.4';
var PageServicesConsRecentProj = '3.1.5';
var PageServicesConsRecentProjItem = '3.1.5.1';
var PageServicesProductDevel = '3.2';
var PageServicesProductWeb = '3.2.1';
var PageServicesProductDatabase = '3.2.2';
var PageServicesProductTelephony = '3.2.3';
var PageServicesProductTurnkey = '3.2.4';
var PageServicesProductNetwork = '3.2.5';
var PageServicesProductSCADA = '3.2.6';
var PageServicesProductPorting = '3.2.7';
var PageServicesInstallation = '3.3';
var PageServicesInstPhysPlant = '3.3.1';
var PageServicesInstTelephone = '3.3.2';
var PageServicesInstSystemSC = '3.3.3';
var PageServicesInstOSInstall = '3.3.4';
var PageServicesInstPkgInstall = '3.3.5';
var PageServicesInstQuietSys = '3.3.6';
var PageServicesRates = '3.4';

var PageProducts = '4';
var PageProductsMailCorral = '4.1';
var PageProductsMCFeatures = '4.1.1';
var PageProductsMCFiltered = '4.1.2';
var PageProductsMCRequirements = '4.1.3';
var PageProductsMCHowItWorks = '4.1.4';
var PageProductsMCDocumentation = '4.1.5';
var PageProductsMCFAQ = '4.1.6';
var PageProductsMCDownloads = '4.1.7';
var PageProductsSpamCorral = '4.2';
var PageProductsSCDocumentation = '4.2.1';
var PageProductsSCDownloads = '4.2.2';
var PageProductsRedirector = '4.3';
var PageProductsRedirDownloads = '4.3.1';
var PageProductsVSuite = '4.4';
var PageProductsVSDownloads = '4.4.1';
var PageProductsVSSubmit = '4.4.2';
var PageProductsDownloads = '4.5';
var PageProductsContribute = '4.6';

var PageReference = '5';
var PageReferenceDocumentation = '5.1';
var PageReferenceInstallNotes = '5.2';
var PageReferenceTechNotes = '5.3';
var PageReferenceSampleCode = '5.4';

var PageResources = '6';
var PageResourcesLinks = '6.1';
var PageResourcesProductsWeUse = '6.2';
var PageResourcesPartners = '6.3';

var PageSearch = '7';

