X-Git-Url: https://git.mdrn.pl/redakcja.git/blobdiff_plain/c7917ce18f0f62eac89e1eb4b6ae6d8c48133600..4251322e9eb5dfbe3ab182fecaafd4c7a5a85b83:/project/static/js/jquery.hpanel.js?ds=sidebyside diff --git a/project/static/js/jquery.hpanel.js b/project/static/js/jquery.hpanel.js index d33e47fb..a3e80ece 100644 --- a/project/static/js/jquery.hpanel.js +++ b/project/static/js/jquery.hpanel.js @@ -5,7 +5,6 @@ settings: {}, current_data: {}, resize_start: function(event, mydata) { - $.log('Overlay: ' + mydata.overlay); $(document).bind('mousemove', mydata, $.hpanel.resize_changed). bind('mouseup', mydata, $.hpanel.resize_stop); @@ -43,10 +42,8 @@ $.fn.makeHorizPanel = function(options) { - $.log('Making an hpanel out of "#' + $(this).attr('id') + '"'); var root = $(this) var all_panels = $('.panel-wrap', root) - $.log('Panels: ' + all_panels); /* create an overlay */ var overlay_root = $("
"); @@ -55,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); @@ -70,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) {