Team:Alberta/LeftBar

From 2009.igem.org

(Difference between revisions)
Line 138: Line 138:
// Menu Functions & Properties
// Menu Functions & Properties
-
//var activeMenu = null;
+
var activeMenu = null;
-
var activeMenu;
+
var lastClicked = null;
function showMenu() {
function showMenu() {
Line 154: Line 154:
     getNextSiblingByElement(this).style.display = "block";
     getNextSiblingByElement(this).style.display = "block";
     activeMenu = this;
     activeMenu = this;
-
     window.name = this;
+
    lastClicked = this;
 +
     window.name = lastClicked;
   }
   }
   return false;
   return false;
Line 171: Line 172:
     a.onclick = showMenu;
     a.onclick = showMenu;
     a.onfocus = function(){this.blur()};
     a.onfocus = function(){this.blur()};
-
     window.name = showMenu;
+
      
   }
   }
 +
 
 +
  activeMenu = window.name;
 +
}
}

Revision as of 22:24, 10 October 2009