mo = [];
mo.images = [];
mo.base = 'template/gfx/menu/';

mo.enter = function(el) {
   if (el.firstChild && this.images[el.firstChild.name]) {
      el.firstChild.src = this.images[el.firstChild.name][1].src;
   }
}

mo.exit = function(el) {
   if (el.firstChild && this.images[el.firstChild.name]) {
      el.firstChild.src = this.images[el.firstChild.name][0].src;
   }
}

mo.preload = function(name, normal, hover) {
   mo.images[name] = [];
   mo.images[name][0] = new Image()
   mo.images[name][0].src = this.base + normal;
   mo.images[name][1] = new Image()
   mo.images[name][1].src = this.base + hover;
}

/* --- Preload images --------------------------------------------- */

