$(document).ready(function(){

  $(".menu li a").mouseover(function () {
    $(this).addClass("hover");
  });
  
  $(".menu li a").mouseout(function () {
    $(this).removeClass("hover");
  });
  
  $(".lista ul li:last").addClass("first");
  		$(".oldshopmenu .file").addClass('')
		$(".oldshopmenu").treeview({
			toggle: function() {
				//alert("%s was toggled.", $(this).find(">span").text());
			},
			collapsed: true
			
		});
  $(".dropdownmenu").hide();
  //var lastSearchTerm = '';
  $(".dropdownmenu").parent("<li>").hover(
    function () {
        $(this).children('.dropdownmenu').show();
        //lastSearchTerm = $("#searchField").val();
        
        //alert($("#hns").parent("form").css("z-index"));
        //alert($("#hns").parent("form").css("zIndex"));
        //$("#hns").parent("form").children("*").hide(); 
        //$("#hns").html("");
        //replace = $('<div id="searchFormReplace">');
        //replace.html("mujdiv mujdiv mujdiv mujdiv mujdiv mujdiv mujdiv mujdiv mujdiv");
        //$("#hns").appendTo(replace);
        
        //$("#searchForm").remove();
        //replace.insertAfter($(".lista"));        
      }, 
      function () {
        //$("#searchFormReplace").remove();
        $(this).children('.dropdownmenu').hide();
        
        //$("#searchFormReplace").children(".submit").appendTo(form);
            
      }
    );
  
});


function Detail(path)
{
	window.open(path, '_blank', 'left=400, top=100, width=226, height=226, resizable=1');
}

function Detail2(path)
{
	window.open(path, '_blank', 'width=600, height=500, resizable=1');
}

function Detail3(path)
{
	window.open("detail3.php?soubor="+path, '_blank', 'width=700, height=500, resizable=1, scrollbars=yes');
}
