//Creating the menu object -- You can call it whatever you want - just remember to
//have the same name as the argument.
slideMenu = new createSlideMenu("slideMenu")
//Variables to set:
slideMenu.menuy=140 //The top placement of the menu.
slideMenu.menux=0 //The left placement of the menu
slideMenu.useImages = 1 //Are you using images or not?
slideMenu.pxspeed=20 //The pixel speed of the animation
slideMenu.timspeed=25 //The timer speed of the animation
slideMenu.inset = 0 //How much the selected items should pop to the left
slideMenu.arrow = 0 //Set this to className that has font-family:webdings
										//if you want to use the arrow feature. Note:
										//This ONLY works on DOM capable browsers, and with
										//useImages set to 0 - It's basically just a test I did.
										//I hope to improve it later on.

//Needed dummy classes - leave in the stylesheet!
slideMenu.bgClass =	"slideMenuBG"
slideMenu.txtClass = "slideMenuText"
slideMenu.persistent=new Object()
if (window.sidePersistentArr) 
    for (nr in sidePersistentArr)
        slideMenu.persistent[sidePersistentArr[nr]]=1
/*******************************************************************************
Level properties - ALL properties have to be specified in level 0
This works the same way as the CM4 script (if you have used it)

The level[0] values will be the default value. Any value not specified
in higher levels will be inherited from level[0]. If anything
is spesified in level[1], but not in level[2], level[2] (sub2 menus)
will get the property value from level[1] and so on.

The availble values to control the menu by level are:

left           - The left placement of all items in the current level ( px value )
width          - The width of all items in the current level  ( px value )
height         - The height of all items in the current level  ( px value )
between        - The number of pixels between each item in  the current level ( px value)
className      - A name of a class specified in the stylesheet to control the
	               look of all items in this level. 
	               NOTE: The class MUST be in a stylesheet, and it most have position:absolute.
classNameA     - A name of a class specified in the stylesheet that will control the 
 								 Look of the TEXT for all items in this level. (you can also specify 
								 a hover class for this className to get a mouseover effect on the 
								 text.
regImage 			 - If you choose to use image feature of the script you have to
                 spesify the default image here.
roundImg       - This is the image that will used when a item is selected.
roundImg2      - This is the image used for sub-levels on the last item in a list.
								 (that's how the last items in this example are rounded on the sub-levels)
subImg         - The image used when the item has sub-items. Only in use for sub-levels
subRound       - Same as roundImg2 - only for items that have sub-items.

To understand the image setup see the images supplied with this script.
NOTE: Always specify the full (relative) path to the images!

The slideMenu_makeLevel function provides a shortcut to making levels.
If you are more comfortable with setting the properties by name you can
also set them like this:

slideMenu.level[0] = new Array()
slideMenu.level[0].left = 0
slideMenu.level[0].width = 138
..... and so on.

NOTE: In level 0 below I have included the names of the variables just for
readability - feel free to remove left = , width = , height = et cetera...
********************************************************************************/

var sidePicsPath="/pics/common/boczne/"

slideMenu.level[0] = new slideMenu_makeLevel(
	left = 0,
	width = 138,
	height = 0,
	between = 5,
	className = "clSlideMenu",
	classNameA = "clA0",
	regImage = '/pics/common/px.gif',
	roundImg = '/pics/common/px.gif',
	roundImg2 = "",
	subImg = "",
	subRound= "",
	classNameOver = "clSlideMenuOver",
	classNameAOver = "clA0Over",
	regImageOn = "/pics/common/px.gif"
)
	
slideMenu.level[1] = new slideMenu_makeLevel(10,127,18,1,"clSlideMenu","clA1",
sidePicsPath+"normal.gif",
sidePicsPath+"normal_arr.png",
sidePicsPath+"level1_round.gif",
sidePicsPath+"normal_arr.png",
sidePicsPath+"level1_sub_round.gif",'','clA1Over',sidePicsPath+"over.gif",
sidePicsPath+'over_arr.png'
)
slideMenu.level[2] = new slideMenu_makeLevel(20,127,18,1,"clSlideMenu","clA2",
sidePicsPath+"normal2.png",sidePicsPath+"level2_round2.gif",
sidePicsPath+"level2_round.gif",
sidePicsPath+"level2_sub.gif",
sidePicsPath+"level2_sub_round.gif",'','clA2Over',
sidePicsPath+'over2.png')
slideMenu.level[3] = new slideMenu_makeLevel(33,108,18,1,"clSlideMenu","clA3",sidePicsPath+"level3_regular.gif",sidePicsPath+"level3_round2.gif",sidePicsPath+"level3_round.gif",sidePicsPath+"level3_sub.gif",sidePicsPath+"level3_sub_round.gif")

//Image preload --- leave this
for(var i=0;i<slideMenu.level;i++){
	var l = slideMenu.level[i]
	new preLoadBackgrounds(l.regImage,l.roundImg,l.roundImg2,
                           l.subImg,l.subRound)
}

fundMBparams = window.fundMBparams ? '?' + window.fundMBparams : ''
var formParams = 'width=750,height=400,scrollbars=yes';

slideMenu.makeMenu('top','')
    slideMenu.makeMenu('sub',"<span class=pomoc>Pomoc</SPAN>", '/private/FundFE/pomoc.shtml')
	slideMenu.makeMenu('sub','Informacje ogólne', '/private/FundFE/info_mb.shtml')
	slideMenu.makeMenu('sub','Analizy i wiadomości', '/private/FundFE/analizy_mb.shtml')
  	slideMenu.makeMenu('sub','Benchmarki','/private/FundFE/bench.shtml');
  	slideMenu.makeMenu('sub','Wyniki zarządzania','/private/FundFE/wyniki_mb.shtml');
	slideMenu.makeMenu('sub','Ryzyko','/private/FundFE/ryzyko_mb.shtml')
    slideMenu.makeMenu('sub','Aktywa','','',1)
  //  slideMenu.makeMenu('sub2','Struktura rynku','/private/FundFE/aktywa_mb_old.shtml')
  //  slideMenu.makeMenu('sub2','Napływ środków','/private/FundFE/aktywa_naplyw_mb_old.shtml')
    slideMenu.makeMenu('sub2','Struktura rynku','/private/FundFE/aktywa_mb.shtml')
    slideMenu.makeMenu('sub2','Napływ środków','/private/FundFE/aktywa_naplyw_mb.shtml')
	slideMenu.makeMenu('sub2','Przelewy ZUS do OFE', '/private/FundFE/zus_do_ofe.shtml')
	slideMenu.makeMenu('sub','Struktura aktywów','/private/FundFE/struktura_aktywow_mb.shtml')
        slideMenu.makeMenu('sub','Portfel akcyjny','','',1)
        slideMenu.makeMenu('sub2','Wartość i struktura','/private/FundFE/portfel_akc_wis_mb.shtml')
        slideMenu.makeMenu('sub2','Składniki','/private/FundFE/portfel_akc_mb.shtml')
        slideMenu.makeMenu('sub','Portfel dłużny','','',1)
        slideMenu.makeMenu('sub2','Wartość i struktura','/private/FundFE/portfel_dlg_wis_mb.shtml')
	slideMenu.makeMenu('sub2','Składniki','/private/FundFE/portfel_dlg_mb.shtml')
	slideMenu.makeMenu('sub2','Dane z MinFin','/private/FundFE/strukt_rynku_dlg.shtml')
        slideMenu.makeMenu('sub','Uczestnicy OFE','','',1)
        slideMenu.makeMenu('sub2','struktura rynku','/private/FundFE/liczba_uczest.shtml')
        slideMenu.makeMenu('sub2','transfery','/private/FundFE/sesje_transfer.shtml')

//Initiating the menu !! 
slideMenu.init()		
slideMenu.switchMenu(sideInitElt)

// aktywa
if(sidePersistentArr[1] > 7 && sidePersistentArr[1] < 11 )
  slideMenu.switchMenu(7)

// portfel akcyjny
if(sidePersistentArr[1] > 12 && sidePersistentArr[1] < 15)
  slideMenu.switchMenu(12)

if(sidePersistentArr[1] > 15 && sidePersistentArr[1] < 19)
  slideMenu.switchMenu(15)

if(sidePersistentArr[1] > 19)
  slideMenu.switchMenu(19)

