$.fn.donnerScroller = function(){ $('#head_logo').height(115); var mcst = 0; var mclastScroll = 0; var mcmaxHeight = $('#head_desktop').height(); var mcminHeight = mcmaxHeight+10; var mcmaxHeightLogo = $('#head_logo').height(); $(window).scroll(function(event){ var mcst = $(this).scrollTop(); if (mcst <= mcminHeight) { $('#head_desktop').height(Math.round(mcmaxHeight-mcst/5)); if ($('#head_logo').height() > 88) { $('#head_logo').height(Math.round(mcmaxHeightLogo-mcst/5)); } else { $('#head_logo').height(115); mcmaxHeightLogo = 115; mcmaxHeight = 115; mcminHeight = 89; } } else { $('#head_desktop').height(Math.round(mcmaxHeight-mcminHeight/5)); if ($('#head_logo').height() > 88) { $('#head_logo').height(Math.round(mcmaxHeightLogo-mcminHeight/5)); } } }); var mcst = $(this).scrollTop(); mclastScroll = mcst; if (mcst >= mcminHeight) { mclastScroll = mcminHeight } if (mcst > 0) { $('#head_desktop').height(Math.round(mcmaxHeight-mclastScroll/5)); $('#head_logo').height(Math.round(mcmaxHeightLogo-mclastScroll/5)); } else { $('#head_desktop').height(Math.round(mcmaxHeight-mclastScroll/5)); } }; function jqUpdateSize(t, o, e) { var i = $(e).width(), n = $(e).height(); return 1 == t ? i : 1 == o ? n : void 0 } function customScrollToPoint(t, o) { $("#" + t).scrollToPoint(o) } function cstp(t, o) { $("#" + t).scrollToPoint(o) } $.fn.center = function() { var t = 0 != $(window).height() ? this.outerHeight() / $(window).height() : 1, o = 0 != $(window).width() ? this.outerWidth() / $(window).width() : 1; return this.css({ position: "fixed", margin: 0, top: 50 * (1 - t) + "%", left: 50 * (1 - o) + "%" }), this }, jQuery.fn.extend({ scrollToPoint: function(t) { if (jQuery(this).offset()) { var o = jQuery(this).offset().top - 100; jQuery("html,body").animate({ scrollTop: o }, t, "easeInOutCubic") } } }), $("img.lazy").show().lazyload({ effect: "fadeIn" }), $(document).ready(function() { $(".jquery_gallery a").lightBox(), $("#infoboxcontent").draggable(), $("#infoboxcontent").center(), $("#fadingBarsG").center(), $("input[type=file]").bootstrapFileInput(), $(".file-inputs").bootstrapFileInput(), $("[data-toggle=popover]").popover({ container: "body", delay: { show: 500, hide: 500 } }), $(window).scroll(function() { $(this).scrollTop() > 280 ? $(".scrollToTop").stop().fadeIn(300, "easeInOutCubic") : $(".scrollToTop").stop().fadeOut(300, "easeInOutCubic") }), $(".scrollToTop").click(function() { return $("html, body").animate({ scrollTop: 0 }, 800, "easeInOutCubic"), !1 }), $("select").selectpicker({ selectedText: "cat" }), $(".mobile_menu").click(function() { $(".ul-firstlevel").toggleClass("visible") }) }); $(window).load(function() { $('.overlay').animate({opacity:0},0),$(function() { $('.fadeInContent').animate({opacity:1},750,'easeInOutSine') }); });