function bindToLightBox(array){
 for(x = 0; x < array.length; x++){
  text = $N('event' + array[x].id,'a');
  text = text[0].innerHTML;
  $('event' + array[x].id).innerHTML = text;
  $('event' + array[x].id).mouseup = array[x].makeLightBox()
 }
}

multiShiftEvent = Class.create();
multiShiftEvent.prototype = {
 initialize:function(id, name,content){
  this.id = id;
  this.name = name;
  this.content = content;
  this.tabs = new Array();
  
  Element.setStyle('event' + this.id, {textDecoration:'underline'});
  $('event' + this.id).onmouseup = this.makeLightBox.bindAsEventListener(this);
 },
 addTab:function(theHeader, theContent, theOptions){
  this.tabs[this.tabs.length] = {header:theHeader, content:theContent, options:theOptions}
 },
 makeLightBox:function(){
  this.lightBox = new LightBox(this.name,this.content,{headerElem:{display:'none'},
                                       frontElem:{width:'430px', display:'block', fontSize:'13px', height:'auto'},
									   okButton:false} );
  accordian = new Accordian('eventAccordian' + this.id,{headerExpandClass:"shiftHeaderExpanded",headerCollapseClass:"shiftHeaderCollapse"});
  for(x = 0; x < this.tabs.length; x++){
   options = (x == 0) ? {expand:true} : {};
   accordian.createTab(this.tabs[x]['header'], this.tabs[x]['content'], options);
  }
  this.lightBox.setElems();
 }
 };

nhsEvent = Class.create();
nhsEvent.prototype = {
 initialize:function(id, name, content){
  this.id = id;
  this.name = name;
  this.content = content;
  
  Element.setStyle('event' + this.id, {textDecoration:'underline'});
 
  $('event' + this.id).onmouseup = this.makeLightBox.bindAsEventListener(this);
 },
  makeLightBox:function(){
   this.lightBox = new LightBox(this.name,this.content,{headerElem:{display:'none'},
                                       frontElem:{width:'430px', display:'block', fontSize:'13px', height:'auto'},
									   okButton:false}
			                          );
					
}
};
