menu_status = new Array();
function showHide(theid){
    if (document.getElementById) {
    var switch_id = document.getElementById(theid);

        if(menu_status[theid] != 'show') {
           switch_id.className = 'show';
           menu_status[theid] = 'show';
        }else{
           switch_id.className = 'hide';
           menu_status[theid] = 'hide';
        }
    }
}

function url_open(id) {
	window.location = id;
}

function image_load(meno) {
o=0;
port_opacity();
document.getElementById("port_win").style.display='inline';
document.getElementById("port_pic").src=meno;
}

function pohyb_okna(event) {
var posy = 0;
if (!e) var e = event;
if (e.pageY) {
posy = e.pageY;
rozdiel=window.innerHeight-e.clientY;
if (rozdiel<=400){
 posy=posy-300;
}
}
else if (e.clientY) {
posy = e.clientY + document.documentElement.scrollTop;
rozdiel= document.documentElement.clientHeight-e.clientY;
if (rozdiel<=400){
 posy=posy-300;
}
}

document.getElementById("port_win").style.top=posy+'px';
document.getElementById("port_win").style.left=event.clientX+10+'px';
}

function port_opacity() {
o=o+0.1;

if (o>=1) {
 o=1;
}

document.getElementById("port_win").style.opacity=o;
document.getElementById("port_win").style.filter='alpha(opacity='+o*100+')';
casovac=setTimeout('port_opacity()',10);
}

function zavri_okno() {
document.getElementById("port_pic").src='/data/logo_loading.jpg';
document.getElementById("port_win").style.display='none';
clearTimeout(casovac);
}

function initialize() {
  if (GBrowserIsCompatible()) {
    var map = new GMap2(document.getElementById("map_canvas"));
    map.setCenter(new GLatLng(48.162598,17.158423), 14);
 
    var point = new GLatLng(48.162598,17.158423);
      
    map.addOverlay(new GMarker(point));
      //  map.setUIToDefault(); // new user control
	map.addControl(new GSmallMapControl());
	map.addControl(new GMapTypeControl());
 
  }
}

