//<script language="javascript">
	function CImageButton( sName, oOnClick, sNormal, sHover, sDisabled )	
	{		
		this.oButton = new Image();
		
		if( sDisabled != "" )
			this.oButton.src = this.sDisabled;

		this.oButton.src = this.sHover;
		this.oButton.src = this.sNormal;		

		this.oButton = ( document.getElementById ) ? document.getElementById( sName ) : (( document.all ) ? document.all[ sName ] : null );
		this.oOnClick = oOnClick;
		this.sNormal = sNormal;
		this.sHover = sHover;
		this.sDisabled = sDisabled;
		this.bSelected = false;
		this.bDisabled = false;
		
		this.OnClick = CImageButton_OnClick;
		this.OnMouseOver = CImageButton_OnMouseOver;
		this.OnMouseOut = CImageButton_OnMouseOut;
		this.SetSelected = CImageButton_SetSelected;
		this.SetDisabled = CImageButton_SetDisabled;
	}

	function CImageButton_OnClick()
	{
		if( this.oOnClick != null )
		{
			this.oOnClick();
		}
	}
	
	function CImageButton_SetDisabled( bDisabled )
	{
		this.bDisabled = bDisabled;
		
		if( this.bDisabled )
		{
			this.oButton.src = this.sDisabled;
		}
		else
		{
			this.oButton.src = this.sNormal;
		}		
	}
	
	function CImageButton_OnMouseOver()
	{
		if( !this.bDisabled )
		{
			if( this.bSelected == false )
				this.oButton.src = this.sHover;
		}
	}
	
	function CImageButton_OnMouseOut()
	{
		if( !this.bDisabled )
		{
			if( this.bSelected == false )
				this.oButton.src = this.sNormal;
		}
	}
	
	function CImageButton_SetSelected( bSelected )
	{
		this.bSelected = bSelected;
		
		if( this.bSelected )
		{
			this.oButton.src = this.sHover;
		}
	}	
//</script>