/**
  * @name: FD.box 
  * @package: Fairfax Digital Javascript Framework 
  * @version: 0.3 
  * @author: Dave Elkan 
  * @copyright: Copyright 2007. Fairfax Digital. 
  * * * * * * * * * * * * * * * * * * * * * * * * * * 
  *             DO NOT ALTER THIS FILE. 
  * If your requirements are not met by this widget 
  * or this widget does not work please ask 
  * Dave Elkan <delkan@fairfaxdigital.com.au>. 
  * This widget is designed to to be used across 
  * the Fairfax Digital Network and contains no  
  * site specific code. 
  * Altering this file will render it unsupportable. 
  * * * * * * * * * * * * * * * * * * * * * * * * * *  
  **/
FD.Box=new Class({displayed:false,spawning:false,options:{className:"box",elementType:"div",zIndex:10},initialize:function(options){this.setOptions(options);this.box=new Element(this.options.elementType);this.box.id=this.options.id;this.box.addClass(this.options.className);this.setZIndex(this.options.zIndex)},injectBox:function(dest){if(!dest){dest=$$("body")[0]}this.box.injectInside(dest)},setZIndex:function(i){if(!isNaN(i)){this.box.setStyle("z-index",i)}},getZIndex:function(){return this.box.getStyle("z-index").toInt()}});FD.Box.implement(new Options);