1 <div class="toolbar" style="height: 24px">
5 <div class="images-wrap" style="position: absolute; top: 24px; left:0px; right:0px; bottom: 0px;">
6 <div class="images"><!-- To jest div na obrazki, które są wstawiane później --></div>
8 <script type="text/javascript" charset="utf-8">
12 var contentDiv = this.contentDiv;
13 $('select[name=folders]', contentDiv).change(function() {
15 $('.images', contentDiv).fadeOut('slow', function() {
16 $(this).html('').load('{% url folder_image_ajax %}' + $(select).val() + '/', function() {
17 $('.images', contentDiv).fadeIn('slow');
18 $('.images-wrap', contentDiv).data('lazyload:lastCheckedScrollTop', -10000);
19 $('.image-box').click(function() {
20 var src = $('img', $(this)).attr('src');
21 var idx = src.lastIndexOf('/');
22 var bigSrc = src.substring(0, idx) + '/big' + src.substring(idx, src.length);
23 var zoom = $('<div style="position: absolute; top: 0; left: 0; right: 0; bottom: 0; overflow: scroll">'
24 + '<img src="' + bigSrc + '" />'
25 + '</div>').click(function() {
28 zoom.appendTo(contentDiv);
34 $('.images-wrap', contentDiv).lazyload('.image-box',
35 {threshold: 640 * 10, scrollTreshold: 640 * 5}
39 return true; // gallery is always fresh
42 return true; // and it doesn't get dirty