
// Here's my demo code for tweaking and shifting the menu. Enjoy :).

// This illustrates changing the contents of the menu -- delete this, it's unnecessary...
// This DOES NOT WORK in Opera yet (as of v6.00 at time of writing) by the way.
function changeMenu() { with (pMenu)
{
 // If your modifications are quite extensive, probably hide the menu before commencing
 // them, as the script relies on the menu array in realtime to handle highlighting etc.
 //over('root', 0);
 //menu.root[0].lyr.vis('hidden');

 // Create a whole new menu...
 startMenu('mNewMenu', true, 0, 22, 130, subM);
 addItem('<b>TwinHelix Designs:</b><br>Extreme DHTML.<br>Small Code.<br>Click to Visit...',
  'window.open("http://www.twinhelix.com")', 'js:', subM, 70);

 // Rebuild the existing root menu to change the text, and pop this out.
 startMenu('root', false, 10, 0, 17, hBar);
 addItem('&nbsp; Rebuilt &gt; &gt;', '#', '', hBar, 80);
 addItem('&nbsp; First', 'mFile', 'sm:', hBar, 50);
 addItem('&nbsp; Second', 'mEdit', 'sm:', hBar, 60);
 addItem('&nbsp; Third', 'mHelp', 'sm:', hBar, 50);
 addItem('&nbsp; Dynamism...', 'mNewMenu', 'sm:', hBar, 80);

 // Change a couple of items in the "File" menu, without rebuilding it.
 menu.mFile[1].text = 'New...';
 menu.mFile[4].text = 'Logoff<br />Menus...';

 // Call the update function to implement our changes.
 update();
}}


// This is just the moving command called when you click the feature list.
function moveRoot()
{
 with (pMenu.menu.root[0].lyr) x( (x()<100) ? 100 : 10);
}
