var newWindowOptions = 'toolbar=yes,location=yes,directories=no,status=no,menubar=no,scrollbars=yes,resizable=yes,copyhistory=no,width=724,height=1020,left=0,top=0';
var newScrollingWindowOptions = 'toolbar=yes,location=yes,directories=no,status=no,menubar=no,scrollbars=yes,resizable=yes,copyhistory=no,width=640,height=480,left=0,top=0';
var newNoScrollWindowOptions = 'toolbar=yes,location=yes,directories=no,status=no,menubar=no,scrollbars=no,resizable=yes,copyhistory=no,width=640,height=480,left=0,top=0';
var newFileWindowOptions = 'toolbar=yes,location=yes,directories=no,status=yes,menubar=yes,scrollbars=yes,resizable=yes,copyhistory=no,width=640,height=480,left=0,top=0';

function addDownArrowNarrow (text) {
return text + '<div style="position:absolute; left:77px; top:4px;"><img src="down_arrow.gif" border=0></div>';
}
function addDownArrow (text) {
return text + '<div style="position:absolute; left:107px; top:4px;"><img src="down_arrow.gif" border=0></div>';
}
function addDownExplorer (text) {
return text + '<div style="position:absolute; left:75px; top:4px;"><img src="down_arrow.gif" border=0></div>';
}

function addRightArrow (text) {
return text + '<div style="position:absolute; left:150px; top:5px;"><img src="arrow_black.gif" border=0 align="center"></div>';
}

function addRightArrowObs (text) {
return text + '&nbsp;&nbsp;&nbsp;<img src="arrow_black.gif" border=0 align="center">';
}


function addRightArrowLong (text) {
return text + '<div style="position:absolute; left:171px; top:5px;"><img src="arrow_black.gif" border=0 align="center"></div>';
}

function addRightArrowExplorer (text) {
return text + '<div style="position:absolute; left:232px; top:5px;"><img src="arrow_black.gif" border=0 align="center"></div>';
}
function addRightArrowExplorerObs (text) {
return text + '&nbsp;&nbsp;&nbsp;<img src="/pdbstatic/images/arrow_black.gif" border=0 align="center">';
}



function newScrollingWindow(url) {
return "javascript:window.open('" + url + "', 'pdb', newScrollingWindowOptions);void(0);";
}

function newWindow(url) {
return "javascript:window.open('" + url + "', 'pdb', newWindowOptions);void(0);";
}

function newFileWindow(url) {
return "javascript:window.open('" + url + "', 'pdb', newFileWindowOptions);void(0);";
}

function openWindow(url) {
  window.open(url, 'pdb', newWindowOptions);void(0);
}

function disabled(title) {
return "<font color='#8e8e8e'>" + title + "</font>";
}

var querydescriptionwindow;
	
function showQueryDescriptionWindow()
{
  if (querydescriptionwindow)
  {
    if (querydescriptionwindow.open)
    {
      querydescriptionwindow.close();
    }
  }
  querydescriptionwindow = window.open("/pdb/search/query.jsp", "querydescriptionwindow", newWindowOptions, true);
}

function checkQueryDescriptionWindow()
{
  // refresh it if it's open
  if (querydescriptionwindow)
  {
    if (querydescriptionwindow.open)
    {
      querydescriptionwindow.location.reload();
    }
  }
}


var MENU_POS=[
// Level 0 block configuration
{
	// Item's height in pixels
	'height'     : 36,
	// Item's width in pixels
	'width'      : 120,
	// if Block Orientation is vertical
	'vertical'   : false,
	// Block outing table parameters:
	// [cellpadding, cellspacing, border]
	'table'      : [0, 1, 0],
	// Time Delay in milliseconds before subling block expands
	// after mouse pointer overs an item
	'expd_delay' : -1,
	// Style class names for the level
	'css' : { 
		'table' : 'mtable', 
		'outer' : ['mouto', 'movero', 'mdowno'],
		'inner' : 'minner'
	}
},
// Level 1 block configuration
{
	'width'      : 169,
	// Vertical Offset between adjacent levels in pixels
	'block_top'  : 28,
	// Horizontal Offset between adjacent levels in pixels
	'block_left' : 12,
	// block behaviour if single frame:	
	// 1 - shift to the edge, 2 - flip relatively to left upper corner
	'wise_pos'   : 1,
	'vertical'   : true,
	// Time Delay in milliseconds before menu collapses after mouse
	// pointer lefts all items
	'hide_delay' : 500,
	// level shadow scope settings
	'shadow' : {
		// horisontal offset of the shadow in pixels
		'offX' : 4,
	// vertical offset of the shadow in pixels
		'offY' : 3,
		// color of the shadow
		'color' : '#888888'
	}
},
// Level 2 block configuration
{
	'width'      : 190,
	// Vertical Offset between adjacent levels in pixels
	'block_top'  : 12,
	// Horizontal Offset between adjacent levels in pixels
	'block_left' : 167
}
]


var MENU_POS_NARROW=[
// Level 0 block configuration
{
	// Item's height in pixels
	'height'     : 36,
	// Item's width in pixels
	'width'      : 90,
	// if Block Orientation is vertical
	'vertical'   : false,
	// Block outing table parameters:
	// [cellpadding, cellspacing, border]
	'table'      : [0, 1, 0],
	// Time Delay in milliseconds before subling block expands
	// after mouse pointer overs an item
	'expd_delay' : -1,
	// Style class names for the level
	'css' : { 
		'table' : 'mtable', 
		'outer' : ['mouto', 'movero', 'mdowno'],
		'inner' : 'minner'
	}
},
// Level 1 block configuration
{
	'width'      : 169,
	// Vertical Offset between adjacent levels in pixels
	'block_top'  : 28,
	// Horizontal Offset between adjacent levels in pixels
	'block_left' : 12,
	// block behaviour if single frame:	
	// 1 - shift to the edge, 2 - flip relatively to left upper corner
	'wise_pos'   : 1,
	'vertical'   : true,
	// Time Delay in milliseconds before menu collapses after mouse
	// pointer lefts all items
	'hide_delay' : 500,
	// level shadow scope settings
	'shadow' : {
		// horisontal offset of the shadow in pixels
		'offX' : 4,
	// vertical offset of the shadow in pixels
		'offY' : 3,
		// color of the shadow
		'color' : '#888888'
	}
},
// Level 2 block configuration
{
	'width'      : 190,
	// Vertical Offset between adjacent levels in pixels
	'block_top'  : 12,
	// Horizontal Offset between adjacent levels in pixels
	'block_left' : 167
}
]



var MENU_POS_EXPLORER=[
// Level 0 block configuration
{
	// Item's height in pixels
	'height'     : 24,
	// Item's width in pixels
	'width'      : 90,
	// if Block Orientation is vertical
	'vertical'   : false,
	// Block outing table parameters:
	// [cellpadding, cellspacing, border]
	'table'      : [0, 1, 0],
	// Time Delay in milliseconds before subling block expands
	// after mouse pointer overs an item
	'expd_delay' : -1,
	// Style class names for the level
	'css' : { 
		'table' : 'mtable', 
		'outer' : ['mouto', 'movero', 'mdowno'],
		'inner' : 'minner'
	}
},
// Level 1 block configuration
{
	'width'      : 250,
	// Vertical Offset between adjacent levels in pixels
	'block_top'  : 20,
	// Horizontal Offset between adjacent levels in pixels
	'block_left' : 12,
	// block behaviour if single frame:	
	// 1 - shift to the edge, 2 - flip relatively to left upper corner
	'wise_pos'   : 1,
	'vertical'   : true,
	// Time Delay in milliseconds before menu collapses after mouse
	// pointer lefts all items
	'hide_delay' : 500,
	// level shadow scope settings
	'shadow' : {
		// horisontal offset of the shadow in pixels
		'offX' : 4,
	// vertical offset of the shadow in pixels
		'offY' : 3,
		// color of the shadow
		'color' : '#888888'
	}
},
// Level 2 block configuration
{
	'width'      : 180,
	// Vertical Offset between adjacent levels in pixels
	'block_top'  : 12,
	// Horizontal Offset between adjacent levels in pixels
	'block_left' : 167
},
// Level 3 block configuration
{
	'width'      : 180,
	// Vertical Offset between adjacent levels in pixels
	'block_top'  : 12,
	// Horizontal Offset between adjacent levels in pixels
	'block_left' : 167
}

]



var MENU_POS_RESULTS=[
// Level 0 block configuration
{
	// Item's height in pixels
	'height'     : 24,
	// Item's width in pixels
	'width'      : 120,
	// if Block Orientation is vertical
	'vertical'   : false,
	// Block outing table parameters:
	// [cellpadding, cellspacing, border]
	'table'      : [0, 1, 0],
	// Time Delay in milliseconds before subling block expands
	// after mouse pointer overs an item
	'expd_delay' : -1,
	// Style class names for the level
	'css' : { 
		'table' : 'mtable', 
		'outer' : ['mouto', 'movero', 'mdowno'],
		'inner' : 'minner'
	}
},
// Level 1 block configuration
{
	'height'     : 36,
	
	'width'      : 169,
	// Vertical Offset between adjacent levels in pixels
	'block_top'  : 20,
	// Horizontal Offset between adjacent levels in pixels
	'block_left' : 12,
	// block behaviour if single frame:	
	// 1 - shift to the edge, 2 - flip relatively to left upper corner
	'wise_pos'   : 1,
	'vertical'   : true,
	// Time Delay in milliseconds before menu collapses after mouse
	// pointer lefts all items
	'hide_delay' : 500,
	// level shadow scope settings
	'shadow' : {
		// horisontal offset of the shadow in pixels
		'offX' : 4,
	// vertical offset of the shadow in pixels
		'offY' : 3,
		// color of the shadow
		'color' : '#888888'
	}
},
// Level 2 block configuration
{
	'width'      : 169,
	// Vertical Offset between adjacent levels in pixels
	'block_top'  : 1,
	// Horizontal Offset between adjacent levels in pixels
	'block_left' : 167
},

// Level 3 block configuration
{
	'width'      : 169,
	// Vertical Offset between adjacent levels in pixels
	'block_top'  : 12,
	// Horizontal Offset between adjacent levels in pixels
	'block_left' : 167
}

]

