All Downloads are FREE. Search and download functionalities are using the official Maven repository.

net.bull.javamelody.resource.monitoring.js Maven / Gradle / Ivy

There is a newer version: 2.3.0
Show newest version
if(document.getElementById("ga-js")){
  var _gaq = _gaq || [];
  _gaq.push(['_setAccount', document.getElementById("ga-js").getAttribute("data-analytics-id")]);
  _gaq.push(['_trackPageview']);
  _gaq.push(['_gat._forceSSL']);
}

(function(){
	function showHide(id){
	  if (document.getElementById(id).style.display=='none') {
	    if (document.getElementById(id + 'Img') != null) {
	      document.getElementById(id + 'Img').src='?resource=bullets/minus.png';
	    }
	    try {
	      document.getElementById(id).style.display=='inline';
	      Effect.SlideDown(id, { duration: 0.5 });
	    } catch (e) {
	      document.getElementById(id).style.display='inline';
	    }
	  } else {
	    if (document.getElementById(id + 'Img') != null) {
	      document.getElementById(id + 'Img').src='?resource=bullets/plus.png';
	    }
	    try {
	      Effect.SlideUp(id, { duration: 0.5 });
	    } catch (e) {
	      document.getElementById(id).style.display='none';
	    }
	  }
	}

	function loadImages(elementId) {
	  var descendents = document.getElementById(elementId).getElementsByTagName('*');
	  for (var i = 0; i < descendents.length; i++) {
	    var element = descendents[i];
	    if (element instanceof HTMLImageElement && element.src == '') {
	      element.src = element.dataset.src;
	    }
	  }
	}

	document.observe('dom:loaded', function(){
	  $$('a.replaceImage').invoke("observe", "mouseover", function(){
	  	document.getElementById(this.getAttribute("data-img-id")).src=this.getAttribute("data-img-src");
	  });

	  // scriptaculous can't animate elements that use a CSS class that sets display: none
	  // so remove that CSS class and set the style property
	  $$('.displayNone').each(function(element){
	    element.style.display = "none";
	    element.classList.remove("displayNone");
	  });
	
	  $$('.selectDatabaseReport').invoke("observe", "change", function(){
	  	window.location.href='?part=database&request=' + this.selectedIndex;
	  });
	
	  $$('.selectDeploymentPeriod').invoke("observe", "change", function(){
	  	document.deploymentPeriodForm.submit();
	  });

	  $$("[data-margin-left-px]").each(function(element){
	  	element.style.marginLeft=element.getAttribute("data-margin-left-px") + "px";
	  });

	  $$(".rumData td[data-width-percent]").each(function(element){
	  	element.style.width=element.getAttribute("data-width-percent") + "%";
	  });

	  if(document.customPeriodForm) {
		// On teste si l'élément  se transforme en 




© 2015 - 2024 Weber Informatics LLC | Privacy Policy