<!--
var Foresee = {
  create: function(){return function() {this.init.apply(this, arguments);};},
  get: function(objId){return document.getElementById(objId);}
};

Foresee.Base = function() {};
Foresee.Base.prototype = {
  errMsg: String = null,
  getErrMsg: function() {return errMsg;},
  clearErrMsg: function() {errMsg = null;},
  getVersion: function() {return 1.0;},
  init: function(){},
  extend: function(object){for(property in object){this[property]=object[property]};return this;},
  getObject: function(obj) {
    if (obj == null) {
      errMsg = "[getObject]: 指定对象为null";
    } else if (typeof(obj) == 'string') {
      obj = document.getElementById(obj);
	  if (obj != null) return obj;
      errMsg = "[getObject]: 指定的ID找不到对象：" + obj;
    } else return obj;
    return null;
  }
};

Foresee.DropdownMenu = Foresee.create();
Foresee.DropdownMenu.prototype = (new Foresee.Base()).extend({
  show: function(objId) {
    var mask=this.getMask(objId);
    var div=this.getObject(objId);
    div.parentNode.appendChild(mask);
    mask.style.visibility = "visible";
    div.style.visibility = "visible";
    mask.style.width=div.offsetWidth;
    mask.style.height=div.offsetHeight;
  },
  hide: function(objId) {
    var mask=this.getMask(objId);
    var div=this.getObject(objId);
    mask.style.visibility = "hidden";
    try{div.parentNode.removeChild(mask);}catch(ex){}
    div.style.visibility = "hidden";
  },
  getMask: function(objId) {

    var maskId="if_mask_" + objId;
    if (this.getObject(maskId) != null) {
      return this.getObject(maskId);
    } else {
      return document.createElement("<iframe id='" + maskId + "' style='position:absolute; visibility:show;' width='1' height='1' scrolling='no' frameborder='0'></iframe>");
    }
  }
});

var fs_menu = new Foresee.DropdownMenu();

-->