/* --- geometry and timing of the menu --- */
// Setup for 10 menu levels add more
var MENU_POS = new Array();
var height = 20
var width = 173;
var first_block_top = 178;
var block_top = 0;
var first_block_left = 0;
var block_left = 140;
var top = height -1;
var left = 0;
var hide_delay = 800;
var onmouseout_background = '#ffffff';
var onmouseout_color = '#000099';
var onmouseover_background = '#0054A5';
var onmouseover_color = '#ffffff';
var onmousedown_background = '#ffffff';
var onmousedown_color = '#000099'; 	// item sizes for different levels of menu
	MENU_POS['height']     = [height, height, height, height, height, height, height, height, height, height];
	MENU_POS['width']      = [width - 10, width, width, width, width, width, width, width, width, width];

	// menu block offset from the origin:
	//  for root level origin is upper left corner of the page
	//  for other levels origin is upper left corner of parent item
	MENU_POS['block_top']  = [first_block_top, block_top, block_top, block_top, block_top, block_top, block_top, block_top, block_top, block_top];
	MENU_POS['block_left'] = [first_block_left, block_left, block_left, block_left, block_left, block_left, block_left, block_left, block_left, block_left];

	// offsets between items of the same level
	MENU_POS['top']        = [top, top, top, top, top, top, top, top, top, top];
	MENU_POS['left']       = [left, left, left, left, left, left, left ,left, left ,left];

	// time in milliseconds before menu is hidden after cursor has gone out
	// of any items
	MENU_POS['hide_delay'] = [hide_delay, hide_delay, hide_delay, hide_delay, hide_delay, hide_delay, hide_delay, hide_delay, hide_delay, hide_delay];

/* --- dynamic menu styles ---
note: you can add as many style properties as you wish but be not all browsers
are able to render them correctly. The only relatively safe properties are
'color' and 'background'.
*/

var MENU_STYLES = new Array();

	// default item state when it is visible but doesn't have mouse over
	MENU_STYLES['onmouseout'] = [
		'background', [onmouseout_background, onmouseout_background, onmouseout_background, onmouseout_background, onmouseout_background, onmouseout_background, onmouseout_background, onmouseout_background, onmouseout_background, onmouseout_background],
		'color', [onmouseout_color, onmouseout_color, onmouseout_color, onmouseout_color, onmouseout_color, onmouseout_color, onmouseout_color, onmouseout_color, onmouseout_color, onmouseout_color],
	];

	// state when item has mouse over it
	MENU_STYLES['onmouseover'] = [
		'background', [onmouseover_background, onmouseover_background, onmouseover_background, onmouseover_background, onmouseover_background, onmouseover_background, onmouseover_background, onmouseover_background, onmouseover_background, onmouseover_background],
		'color', [onmouseover_color, onmouseover_color, onmouseover_color, onmouseover_color, onmouseover_color, onmouseover_color, onmouseover_color, onmouseover_color, onmouseover_color, onmouseover_color],
	];

	// state when mouse button has been pressed on the item
	MENU_STYLES['onmousedown'] = [
		'background', [onmousedown_background, onmousedown_background, onmousedown_background, onmousedown_background, onmousedown_background, onmousedown_background, onmousedown_background, onmousedown_background, onmousedown_background, onmousedown_background],
		'color', [onmousedown_color, onmousedown_color, onmousedown_color, onmousedown_color, onmousedown_color, onmousedown_color, onmousedown_color, onmousedown_color, onmousedown_color, onmousedown_color],
	];
	