//var tel = Navigo2.DAO.getMessage('javascript.hint.phone.contraction');
var more = Navigo2.DAO.getMessage('common.text.more');
if(more == undefined) {
	more = 'Pokaż więcej';
}
var loc = (locale!=undefined) ? '_'+locale : '';

tooltip_brief_body = "#{info.description}<br/><br/>" +
		"#{address.street} #{address.no}<br/>#{address.zipCode}#{address.city}";

tooltip_detailed_body = function(poi) {

	var templ = "";
	var lines = 4;

	if (Navigo2.DAO.getPackage() == 'gold') {
		templ +=  "<img src=\""
                + "/navigo/getCurrentMap.png?x=#{x}&y=#{y}&s=15000&w=100&h=100"
                + "&i=#{id}"
                + "&uname=" + uname
                + "&adapter=" + adapter
                + "&locale=" + locale
                + "&iconURL=#{poisImgURL}"
                + "\" align=\"right\" width=\"100\" height=\"100\" />";
	}

	templ +="#{html}";

					//link
					if (poi.customFields['link' + loc] != undefined && poi.customFields['link' + loc] != "") {
						templ += "<br/><a href=\"" + poi.customFields['link' + loc] + "\"><u><font color=\"#737373\">" + more + "...</font></u></a><br/>";
						lines++;
						//alert(poi.customFields.link);
					}

					templ += "<br/>#{address.street} #{address.no}<br/>#{address.zipCode}#{address.city}";
                
					//phone
					if (poi.customFields.phone != undefined && poi.customFields.phone != "") {
						var tel = Navigo2.DAO.getMessage('javascript.hint.phone.contraction');
						templ += "<br/>" + tel +": " + poi.customFields.phone;
						lines++;
					}
					
					//fax
					if (poi.customFields.fax != undefined && poi.customFields.fax != "") {
						templ += "<br/>Fax: " + poi.customFields.fax;
						lines++;
					//	alert(poi.customFields.fax);
					}
					
					//email
					if (poi.customFields.email != undefined && poi.customFields.email != "") {
						templ += "<br/><a href=\"mailto:" + poi.customFields.email + "\"><u><font color=\"#737373\">" + poi.customFields.email + "</font></u></a>";
						lines++;
					//	alert(poi.customFields.email);
					}
					
					//www
					if (poi.customFields.www != undefined && poi.customFields.www != "") {
						templ += "<br/><a href=\"http://" + poi.customFields.www + "\" target=\"_blank\"><u><font color=\"#737373\">" + poi.customFields.www + "</font></u></a>";
						lines++;
					}
									
					if (poi.html != undefined && poi.html.length > 0) {
						lines -= Math.ceil(poi.html.length / 32);
						if (lines < 0) {
							lines = 0;
						}
					}				
										
					//image.url
					if (poi.image.url != undefined && poi.image.url != "") {
						for (var i = 0; i < lines; i++) {
							templ += "<br/>";
						}
						templ += "<br/><img src=\"" + poi.image.url + "\" align=\"right\" width=\"" + poi.image.width + "\" height=\"" + poi.image.height + "\"/>";
					}
                return templ;
/*
//	tooltip_detailed_body += "<br/>" + tel +": #{customFields.phone}";
	tooltip_detailed_body += "#{customFields.phone}";

//	tooltip_detailed_body += "<br/>fax: #{customFields.fax}";
	tooltip_detailed_body += "#{customFields.fax}";

//	tooltip_detailed_body += "<br/><a href=\"mailto:#{customFields.email}\"><u><font color=\"#737373\">#{customFields.email}</font></u></a>"; 
	tooltip_detailed_body += "#{customFields.email}"; 

//	tooltip_detailed_body += "<br/><a href=\"http://#{customFields.www}\" target=\"_blank\"><u><font color=\"#737373\">#{customFields.www}</font></u></a>";
	tooltip_detailed_body += "#{customFields.www}";

//	tooltip_detailed_body += "<br/><a href=\"http://#{customFields.link" + loc + "}\"><u><font color=\"#737373\">#{customFields.link" + loc + "}</font></u></a>"; 
	tooltip_detailed_body += "#{customFields.link}"; 

//	tooltip_detailed_body += "<br/><img src=\"#{image.url}\" align=\"right\" width=\"#{image.width}\" height=\"#{image.height}\"/>";
	tooltip_detailed_body += "#{image.url}";
*/	
}
tooltip_label_body ="#{info.name}";
