/*****************************************************
Add-in to have different offsets x y on the same level
******************************************************/
makeCM.prototype.onshow+=";this.offsetxypos(b,pm,pm.subx,pm.suby,maxw,maxh)"
makeCM.prototype.offsetxypos=function(b,pm,x,y,w,h,n){
  if (pm.lev == 0) {
    var offset = 0;
    for (var i=0; i<this.l[0].m.length; i++) {
      if (this.l[0].m[i] == pm.name)
        break;
      offset++;
    }

    b.moveIt(x,y+1); //sox soy definded in the menu above onmouseover sox=20 soy=10
  }
}

makeCM.prototype.activate = function(contentID) {
  var pm = this.m[contentID];
  if (!pm)
    return;


  var items = new Array(pm);
  while (pm.parent) {
    pm = this.m[pm.parent];
    items[items.length] = pm;
  }
  items = items.reverse();
  for (var i=0; i<items.length; i++)
    this.showsub(items[i].name);
}

makeCM.prototype.onshow+=";this.hideFlash()";
makeCM.prototype.hideFlash = function() {
  var el = document.getElementById("introFlash");
  if (el) el.style.display = "none";
}

makeCM.prototype.onconstruct+=";this.udateMenu()";
makeCM.prototype.udateMenu = function() {
  var topM = this.l[0].m;
  for (var i=0; i<topM.length; i++) {
    var mi = this.m[topM[i]];
    var smi = this.m[mi.subs[0]];
    //mi.lnk = smi.lnk;
  }
}
