Line | |
---|
1 | jQuery("document").ready(function(jQuery) { |
---|
2 | |
---|
3 | // SlideZone autosize function |
---|
4 | |
---|
5 | if (options.imageAutosize) { |
---|
6 | |
---|
7 | jQuery(window).resize(function () { |
---|
8 | |
---|
9 | var Fenetre = jQuery(window); |
---|
10 | var the_page = jQuery("#the_page"); |
---|
11 | var imgSlideZone = jQuery(".imgSlideZone"); |
---|
12 | var imgSlideImg = jQuery(".imgSlideImg"); |
---|
13 | |
---|
14 | if (imgSlideZone.length == 0) return; |
---|
15 | |
---|
16 | var marge = the_page.height() - imgSlideImg.height(); |
---|
17 | |
---|
18 | var Hmin = options.imageAutosizeMinHeight; |
---|
19 | |
---|
20 | var newH = Fenetre.height() - marge; |
---|
21 | if (newH < Hmin) newH = Hmin; |
---|
22 | if (newH > SlideMaxHeight) newH = SlideMaxHeight; |
---|
23 | imgSlideImg.css("height",newH+"px"); |
---|
24 | |
---|
25 | return; |
---|
26 | |
---|
27 | }); |
---|
28 | |
---|
29 | jQuery(window).resize(); |
---|
30 | jQuery(window).resize(); |
---|
31 | |
---|
32 | } |
---|
33 | |
---|
34 | }); |
---|
Note: See
TracBrowser
for help on using the repository browser.