X-Git-Url: https://git.mdrn.pl/redakcja.git/blobdiff_plain/b157bbf02932396c65c0aca9638c96200c4665df..1177b1bdf74626d1edf681ae530e9d5f2e1a76a8:/project/static/js/jquery.hpanel.js diff --git a/project/static/js/jquery.hpanel.js b/project/static/js/jquery.hpanel.js index 2f917a88..abb7a5bc 100644 --- a/project/static/js/jquery.hpanel.js +++ b/project/static/js/jquery.hpanel.js @@ -35,8 +35,8 @@ $(this).data('panel').css({ 'left': $(this).css('left'), 'width': $(this).css('width')}); }); - $('.panel-overlay', event.data.root).css('display', 'none'); + $(event.data.root).trigger('stopResize'); } }; @@ -52,10 +52,9 @@ var prev = null; all_panels.each(function(i) { - var panel = $(all_panels[i]); + var panel = $(this); var handle = $('.panel-slider', panel); - - var overlay = $("

Panel #"+i+"

"); + var overlay = $("

Panel #"+i+"

"); overlay_root.append(overlay); overlay.data('panel', panel); overlay.data('next', null); @@ -67,7 +66,8 @@ if (prev) prev.next = overlay; - if(handle) { + if(handle.length != 0) { + $.log('Has handle: ' + panel.attr('id') ); overlay.append(handle.clone()); /* attach the trigger */ handle.mousedown(function(event) {