function TLabel(){}TLabel.prototype.initialize=function(d){this.parentMap=d;var c=document.createElement("span");c.setAttribute("id",this.id);c.innerHTML=this.content;document.body.appendChild(c);c.style.position="absolute";c.style.zIndex=1;if(this.percentOpacity){this.setOpacity(this.percentOpacity)}this.w=document.getElementById(this.id).offsetWidth;this.h=document.getElementById(this.id).offsetHeight;this.mapTray=d.getPane(G_MAP_FLOAT_PANE);this.mapTray.appendChild(c);if(!this.markerOffset){this.markerOffset=new GSize(0,0)}this.setPosition();GEvent.bind(d,"zoomend",this,function(){this.setPosition()});GEvent.bind(d,"moveend",this,function(){this.setPosition()})};TLabel.prototype.setPosition=function(a){if(a){this.anchorLatLng=a}var b=this.parentMap.fromLatLngToDivPixel(this.anchorLatLng);var x=parseInt(b.x);var y=parseInt(b.y);with(Math){switch(this.anchorPoint){case"topLeft":break;case"topCenter":x-=floor(this.w/2);break;case"topRight":x-=this.w;break;case"midRight":x-=this.w;y-=floor(this.h/2);break;case"bottomRight":x-=this.w;y-=this.h;break;case"bottomCenter":x-=floor(this.w/2);y-=this.h;break;case"bottomLeft":y-=this.h;break;case"midLeft":y-=floor(this.h/2);break;case"center":x-=floor(this.w/2);y-=floor(this.h/2);break;default:break}}var d=document.getElementById(this.id);if(d){d.style.left=x-this.markerOffset.width+"px";d.style.top=y-this.markerOffset.height+"px"}};TLabel.prototype.setOpacity=function(a){if(a<0){a=0}if(a>100){a=100}var f=a/100;var e=document.getElementById(this.id);if(typeof(e.style.filter)=="string"){e.style.filter="alpha(opacity:"+a+")"}if(typeof(e.style.KHTMLOpacity)=="string"){e.style.KHTMLOpacity=f}if(typeof(e.style.MozOpacity)=="string"){e.style.MozOpacity=f}if(typeof(e.style.opacity)=="string"){e.style.opacity=f}};GMap2.prototype.addTLabel=function(b){b.initialize(this)};GMap2.prototype.removeTLabel=function(d){var c=document.getElementById(d.id);this.getPane(G_MAP_FLOAT_PANE).removeChild(c);delete (c)};