function FloatingWin( element, textElement ) {
	var self 		= this;			//	Needed for methods to be able to call each other
	this.myEl		= element;
	this.myTextEl	= textElement;
	
	this.SetText = function( newText ) {
		self.myTextEl.innerHTML = newText;
	}
	
	/**
	 *	Moves the floaterContainer object
	 *	@param	int				Destination.  Note that we add a 'px' to these when setting them.
	 *	@access	public
	 */
	this.Move = function( newX, newY) {
//		alert('theFloater = ' + theFloater );
//		alert('theFloater.style.left = ' + parseInt(theFloater.style.left));
//		alert('Moving to '+newX + ',' + newY);
		self.myEl.style.left	= newX+'px';
		self.myEl.style.top		= newY+'px';		
//		alert('theFLoater.style.left = ' + theFloater.style.left);
	}
	
	this.Hide = function() {
		self.myEl.style.visibility = "hidden";									//	Won't work on NN4
	}
	
	this.Show = function() {
		self.myEl.style.visibility = "visible";									//	Won't work on NN4
	}
	
	//	relX and relY are the x,y coordinate relative to the container the floater is pointing to
	//	e.g. the relative position of the click to the map
	//	absX and absY are the x,y coordinates of the container, e.g. the origin of the map
	this.DisplayAt = function( relX, relY, containerObjID, newText ) { 
		self.SetText( newText );

		var containerObj = document.getElementById( containerObjID );
		var absX = containerObj.offsetLeft;
		var absY = containerObj.offsetTop;
	//	alert ( 'containerObj = ' + containerObj + ':: absX = ' + absX + ' absY = ' + absY)
		var fX	= parseInt(relX) + parseInt(absX);
		var fY	= parseInt(relY) + parseInt(absY);
	//	alert( 'fx = ' + fX + ' fy = ' + fY )
		fY -= self.myEl.clientHeight;
		self.Move( fX, fY );

		self.Show();
	}
	
	this.Listener = function( event ) {
		self.Hide();
	}
}
	
/*
<!-- Copy this to the web page -->
<script type="text/javascript">	
	function InitFloater( relX, relY, containerObjID, newText ) {
		//	compareBtn
		floatWinElement = document.getElementById('floaterContainer');
		floatWinTextEl	= document.getElementById('floaterText');
		floatWin		= new FloatingWin( floatWinElement, floatWinTextEl );
		
		addEvent(floatWinElement, 'click', floatWin.Listener, false);
		
		floatWin.DisplayAt( relX, relY, containerObjID, newText );
	}
</script>

<div id="floaterContainer">
	<table id="floater" border='0' cellspacing='0' cellpadding='0'>
		<tr>
			<td id="floaterBG">
				<table>
					<tr>
						<td id="floaterText">
							junk
						</td>
						<td>
							<div id="floaterCloseBtn"><a href='#'>X</a></div> 
						</td>
					</tr>
				</table>
			</td>
		</tr>
	</table>
</div>
*/
