// Cascading Popup Menus v5.2 - Single Frame Menu example script.



// 'horizontal Bar' style: menu items that use this ItemStyle are 40px wide, have 10px gaps
// between them, no popout indicator (the ">" in some menus) or popout indicator position,
// 0px padding of the text within items, #336699 background colour, a hover colour of #6699CC,
// 'highText' is the stylesheet class used for the menu text both normally and when highlighted,
// no border styles, 'null' means fully opaque items (set them to numbers between 0 and 100 to
// enable semitranslucency), and the 'hand'/'default' cursors are used for linked/submenu items.
var hBar = new ItemStyle(40, 10, '', 0, 0, '', '10#EDE9FD', 'highText', 'highText', '', '',
 null, null, 'hand', 'default');

// The 'sub Menu' items: these have popout indicators of "Greater Than" signs ">" 15px from their
// right edge, and CSS borders. Text class also changes on mouseover.
var subM = new ItemStyle(22, 0, '>', -15, 3, '#CCCCDD', '#6699CC', 'lowText', 'highText',
 'itemBorder', 'itemBorder', null, null, 'hand', 'default');

// 'subBlank' is similar, but has an 'off' border the same colour as its background so it
// appears borderless when dim, and 1px spacing between items to show the hover border.
var subBlank = new ItemStyle(22, 1, '>', -15, 3, '#CCCCDD', '#6699CC', 'lowText', 'highText',
 'itemBorderBlank', 'itemBorder', null, null, 'hand', 'default');

// The purplish 'button' style also has 1px spacing to show up the fancy border, and it has
// different colours/text and less padding. They also have translucency set -- these items
// are 80% opaque when dim and 95% when highlighted. It uses the 'crosshair' cursor for items.
var button = new ItemStyle(22, 1, '>', -15, 2, '10#d9dad7', '10#C5BBD3', 'buttonText', 'buttonHover',
 'buttonBorder', 'buttonBorderOver', 100, 90, 'default', 'default');

//var navRoot = new ItemStyle(0, 0, '', 0, 0, 'images/btn-home.gif', 'images/btn-home-on.gif', 'nav',  'nav', '',  '', null, null, 'hand', 'default');

//var navRoot1 = new ItemStyle(0, 0, '', 0, 0, 'images/btn-solutions.gif', 'images/btn-solutions.gif', 'nav',  'nav', '',  '', null, null, 'hand', 'default');

try {
  eval(homeTab);
  var Menu1 = new ItemStyle(0, 0, '', 0, 0, '/images/tab-home.gif', '/images/tab-home.gif', 'buttonText', 'buttonHover', '', '', null, null, 'hand', 'default');
} catch (e) {
  var Menu1 = new ItemStyle(0, 0, '', 0, 0, '/images/btn-home.gif', '/images/btn-home-on.gif', 'buttonText', 'buttonHover', '', '', null, null, 'hand', 'default');
}


try {
  eval(serviceTab);
  var Menu2 = new ItemStyle(0, 0, '', 0, 0, '/images/tab-services.gif', '/images/tab-services.gif', 'buttonText', 'buttonHover', '', '', null, null, 'hand', 'default');
} catch(e) {
  var Menu2 = new ItemStyle(0, 0, '', 0, 0, '/images/btn-services.gif', '/images/btn-services-on.gif', 'buttonText', 'buttonHover', '', '', null, null, 'hand', 'default');
}

try {
  eval(galleryTab);
  var Menu3 = new ItemStyle(0, 0, '', 0, 0, '/images/tab-gallery.gif', '/images/tab-gallery.gif', 'buttonText', 'buttonHover', '', '', null, null, 'hand', 'default');
} catch(e) {
  var Menu3 = new ItemStyle(0, 0, '', 0, 0, '/images/btn-gallery.gif', '/images/btn-gallery-on.gif', 'buttonText', 'buttonHover', '', '', null, null, 'hand', 'default');
}

try {
  eval(couponsTab);
  var Menu4 = new ItemStyle(0, 0, '', 0, 0, '/images/tab-coupons.gif', '/images/tab-coupons.gif', 'buttonText', 'buttonHover', '', '', null, null, 'hand', 'default');
} catch(e) {
  var Menu4 = new ItemStyle(0, 0, '', 0, 0, '/images/btn-coupons.gif', '/images/btn-coupons-on.gif', 'buttonText', 'buttonHover', '', '', null, null, 'hand', 'default');
}

try {
  eval(testimonialsTab);
  var Menu5 = new ItemStyle(0, 0, '', -0, 0, '/images/tab-testimonials.gif', '/images/tab-testimonials.gif', 'buttonText', 'buttonHover', '', '', null, null, 'hand', 'default');
} catch(e) {
  var Menu5 = new ItemStyle(0, 0, '', -0, 0, '/images/btn-testimonials.gif', '/images/btn-testimonials-on.gif', 'buttonText', 'buttonHover', '', '', null, null, 'hand', 'default');
}

try {
  eval(aboutTab);
  var Menu6 = new ItemStyle(0, 0, '', -0, 0, '/images/tab-about.gif', '/images/tab-about.gif', 'buttonText', 'buttonHover', '', '', null, null, 'hand', 'default');
} catch(e) {
  var Menu6 = new ItemStyle(0, 0, '', -0, 0, '/images/btn-about.gif', '/images/btn-about-on.gif', 'buttonText', 'buttonHover', '', '', null, null, 'hand', 'default');
}



// Create a PopupMenu() object, and pass its own name so it can reference itself later on.
// We also use a 'with' block to work with its properties and functions below.

var pMenu = new PopupMenu('pMenu');
with (pMenu)
{

// The example 'root' menu is horizontal (false), positioned at (x = 10, y = 0), is 17px high,
// and items use the colours and dimensions in the 'hBar' ItemStyle defined above by default.
// If you want a vertical menu, change "false" to "true", and raise 17 to about 100 for the width.
// Most of these are 'sm:' items popping out submenus, except the last 'js:' JavaScript command to
// pop open a new window. It also has its own ItemStyle and width specified, longer than the rest.

startMenu('root', false,  310, 277, 19, hBar );

addItem('&nbsp;&nbsp; ', 'mMenu1', 'sm:', Menu1, 71).onclick = 'location.href="/"';
addItem('&nbsp;&nbsp; ', 'mMenu2', 'sm:', Menu2, 95).onclick = 'location.href="/services/rates.php"';
addItem('&nbsp;&nbsp; ', 'mMenu3', 'sm:', Menu3, 84).onclick = 'location.href="/gallery"';
addItem('&nbsp;&nbsp; ', 'mMenu4', 'sm:', Menu4, 95).onclick = 'location.href="/coupons/coupons.php"';
addItem('&nbsp;&nbsp; ', 'mMenu5', 'sm:', Menu5, 138).onclick = 'location.href="/testimonials"';
addItem('&nbsp;&nbsp; ', 'mMenu6', 'sm:', Menu6, 94).onclick = 'location.href="/about/index.php"';
//addItem('  Visit My Site', 'window.open("http://www.twinhelix.com")', 'js:', hBar, 80);


// This is a vertical menu positioned 0px across and 22px down from its trigger, and is 80px wide.
// The URLs are set to # here, be sure to replace them with your path/file names or JS functions!
// Also note how the types are '', indicating these links open in the current frame/window.
// The last item here changes its text on mouseover (^ separates the two strings), links to my site,
// and has a custom ItemStyle and length specified so it's longer than the rest.

startMenu('mMenu1', true, 0, 25, 120, subM);
//addItem('Main Page', 'index.php', '',button,22,0);
//addItem('Screen Shots', 'screenshots.html', '',button,22,0);
//addItem('Project Timeline', 'timeline.html', '',button,22,0);
//addItem('Development Info', 'mReopen', 'sm:',button,22,0);

//addItem('TwinHelix', 'window.open("http://www.twinhelix.com")', 'js:', button,22,0);


startMenu('mMenu2', true, 0, 25, 160, subM);
addItem('<b>Rates</b>', '/services/rates.php', '',button,22,0).onclick = 'location.href="rates/"';
addItem('<b>Custom Jewelry Design</b>', '/services/custom.php', '',button,22,0);
addItem('<b>Insurance Appraisals</b>', '/services/appraisal.php', '',button,22,0).onclick = 'location.href="appraisal/"';
addItem('<b>Watch Repair</b>', '/services/watch.php', '',button,22,0);
addItem('<b>Diamond Guide</b>', '/services/guide.php', '',button,22,0);
addItem('<b>Industry Links</b>', '/services/links.php', '',button,22,0);
addItem('<b>Gold/Diamond Purchasing</b>', '/services/GoldDiamondPurchasing.php', '',button,22,0).onclick = 'location.href="GoldDiamondPurchasing/"';
//addItem('<b>Insurance Appraisals</b>', '/services/appraisals.php', '',button,22,0).onclick = 'location.href="corals/"';

//addItem('<b>Custom Solutions</b>', 'corals/custom.php', '',button,22,0);
//addItem('<b>Case Studies</b>', 'corals/corals-studies.php', '',button,22,0);

// Submenu items for 'Common Applications'
                //startMenu('mCommon', true, 165, 0, 140, subM);
               // addItem('Surveys and Studies', 'solutions/surveys-studies.php', '', button, 25);
                //addItem('Tasks and Time', 'solutions/reporting.php', '', button, 25);
               // addItem('HR', 'solutions/hr.php', '', button, 25);
               // addItem('FAQ', 'solutions/faq.php', '', button, 25);
              //  addItem('Scheduling', 'solutions/scheduling.php', '', button, 25);
              // addItem('Outbound Campaigns', 'solutions/autocaller.php', '', button, 25);
                //addItem('Dispatch', 'solutions/dispatch.php', '', button, 25);
               // addItem('Store Locator', 'solutions/locator.php', '', button, 25);
                //addItem('Crisis Management', 'solutions/crisis.php', '', button, 25);
               // addItem('Notification', 'solutions/notification.php', '', button, 25);


                //startMenu('mIndustry', true, 165, 0, 140, subM);
                //addItem('Call Centers', 'solutions/callcenter.php', '', button, 25);
                //addItem('Finance', 'solutions/finance.php', '', button, 25);
                //addItem('Healthcare', 'solutions/healthcare.php', '', button, 25);
                //addItem('Government', 'solutions/government.php', '', button, 25);
                //addItem('Retail', 'solutions/retail.php', '', button, 25);
                //addItem('Transportation', 'solutions/transportation.php', '', button, 25);
                //addItem('Utilities', 'solutions/utilities.php', '', button, 25);



// Product Menu
startMenu('mMenu3', true, 0, 25, 100, subM);
addItem('<b>Diamonds</b>', '/gallery/jewelry-diamonds', '',button,26,0);
addItem('<b>Gold</b>', '/gallery/jewelry-gold', '',button,26,0).onclick = 'location.href="technology/platform-software.php"';
addItem('<b>Pearls</b>', '/gallery/jewelry-pearls', '',button,26,0);
addItem('<b>Gemstones</b>', '/gallery/jewelry-gemstones', '',button,26,0);
addItem('<b>Watches</b>', '/gallery/jewelry-watches', '',button,26,0);
addItem('<b>Custom Designs</b>', '/gallery/jewelry-custom', '',button,26,0);
addItem('<b>Bridal</b>', '/gallery/jewelry-bridal', '',button,26,0);
addItem('<b>Beachcomber +</b>', '/gallery/Cape-Cod-Beachcomber', '',button,26,0);
                // Submenu items for VoiceXML Platform
                //startMenu('mPlatform', true, 165, 0, 140, subM);
                //addItem('Backgrounder', 'technology/backgrounder.php', '', button, 25);
                //addItem('Architecture', 'technology/architecture', '', button, 25);
                //addItem('VoiceXML Interpreter', 'technology/interpreter.php', '', button, 25);
                //addItem('Admin Tools', 'technology/admin-tools.php', '', button, 25);
                //addItem('Application Tools', 'technology/application-tools.php', '', button, 25);

                // Submenu items for Hosted Gateways
                //startMenu('mHosted', true, 165, 0, 140, subM);
                //addItem('Facilities', 'technology/facility.php', '', button, 25);



// Drygoods Menu
//startMenu('mMenu4', true, 0, 25, 180, subM);
//addItem('<b>additives/test kits</b>', '/drygoods/index.php', '',button,22,0);
//addItem('<b>books</b>', '/drygoods', '',button,26,0).onclick = 'location.href="/drygoods/index.php"';
//addItem('<b>media reactors</b>', '/drygoods/index.php', '',button,22,0);
//addItem('<b>food</b>', '/drygoods/index.php', '',button,22,0);
//addItem('<b>heater/chillers</b>', '/drygoods/index.php', '',button,22,0);
//addItem('<b>lighting</b>', '/drygoods/index.php', '',button,22,0);
//addItem('<b>pumps/powerheads</b>', '/drygoods/index.php', '',button,22,0);
//addItem('<b>protein skimmers</b>', '/drygoods/index.php', '',button,22,0);


                // Submenu items for Custom Systems
                //startMenu('mCustomSystems', true, 165, 0, 140, subM);
                //addItem('3 Step Process', 'support/solution-process.php', '', button, 25);



// Sales Menu
startMenu('mMenu5', true, 0, 25, 138, subM);
addItem('<b>View Feedback</b>', '/testimonials/', '',button,22,0);
addItem('<b>Leave Feedback</b>', '/testimonials/feedback.php', '',button,22,0);
//addItem('<b>Free Dev Site</b>', 'sales/devsite.php', '',button,22,0);
//addItem('<b>Free Trial Software</b>', 'sales/freetrial.php', '',button,22,0);
//addItem('<b>Application Partnerships</b>', 'sales/applicationpartners.php', '',button,22,0);
//addItem('<b>Reseller Opportunities</b>', 'sales/partnership-opportunities.php', '',button,22,0);



// About Us Menu
startMenu('mMenu6', true, 0, 25, 94, subM);
addItem('<b>History </b>', '/about/index.php', '',button,22,0);
addItem('<b>Store Hours</b>', '/about/hours.php', '',button,22,0);
addItem('<b>Directions</b>', '/about/directions.php', '',button,22,0);
addItem('<b>Return Policy</b>', '/about/Return Policy.php', '',button,22,0);
addItem('<b>Our Blog</b>', '/about/OurBlog.php', '',button,22,0);
addItem('<b>Our Staff</b>', '/about/Our Staff.php', '',button,22,0);
//addItem('<b>careers</b>', '/aboutus/careers.php', '',button,22,0);





// You can also customise hide or show delays (in milliseconds) to the menus. Defaults are:
//showDelay = 0;
//hideDelay = 500;
// Specify hideDelay as zero if you want to disable autohiding, and showDelay as a couple of
// hundred if you don't want the menus showing instantaneously when moused over.
//
// You can assign 'oncreate' events to specific menus. By default, the script has only one for
// the root menu that shows it when it is created. You may wish to change it to something like the
// following, which uses the animation function to show the menu, or delay its show altogether.
//menu.root[0].oncreate = function() { pMenu.doVis('root', true) }

// End of 'with (pMenu)' block. That's one menu object created!

}



// CREATE ANOTHER MENU OBJECT here if you want multiple menus on a page, or you can just
// duplicate this entire file and rename 'pMenu' to something else.
// Every menu object MUST have a menu named 'root' in it, as that's always visible.

//var anotherMenu = new PopupMenu('anotherMenu');
//with (anotherMenu)
//{
// startMenu('root', .....);
// ... make menus here ...
//}


