Difference between revisions of "Team:Marburg/Gallery"
Line 220: | Line 220: | ||
z-index:1; | z-index:1; | ||
height:450px; | height:450px; | ||
− | |||
padding:10px; | padding:10px; | ||
opacity:0.0; | opacity:0.0; | ||
Line 378: | Line 377: | ||
$.fn.initGallery = function() { | $.fn.initGallery = function() { | ||
//SCALE CONTAINER | //SCALE CONTAINER | ||
− | + | var fades = $('img',this); | |
− | + | var maxwidth = 0; | |
− | + | var maxheight = 0; | |
− | + | fades.each(function() { | |
//maxwidth = ($(this).outerWidth() > maxwidth) ? $(this).outerWidth() : maxwidth; | //maxwidth = ($(this).outerWidth() > maxwidth) ? $(this).outerWidth() : maxwidth; | ||
//maxheight = ($(this).outerHeight() > maxheight) ? $(this).outerHeight() : maxheight; | //maxheight = ($(this).outerHeight() > maxheight) ? $(this).outerHeight() : maxheight; | ||
}); | }); | ||
− | + | this.height( maxheight ); | |
− | + | this.width( maxwidth ); | |
//FIX IMAGE POSITIONS | //FIX IMAGE POSITIONS | ||
fades.each(function() { | fades.each(function() { |
Revision as of 14:57, 16 September 2015