X-Git-Url: https://git.heureux-cyclage.org/?a=blobdiff_plain;f=resources%2Fsrc%2Fjquery%2Fjquery.arrowSteps.js;h=b0c36c654851482b40d1dd0b4c9cfd989a6c3f59;hb=951c1016edbf1325119b814cd0e6a30e104868b4;hp=f8641e1043d5208d3a902f3588212759b8a4cc83;hpb=1a8daf2c07e31337d83ee39b42873373023c8d40;p=lhc%2Fweb%2Fwiklou.git diff --git a/resources/src/jquery/jquery.arrowSteps.js b/resources/src/jquery/jquery.arrowSteps.js index f8641e1043..b0c36c6548 100644 --- a/resources/src/jquery/jquery.arrowSteps.js +++ b/resources/src/jquery/jquery.arrowSteps.js @@ -51,7 +51,7 @@ $stepDiv = $steps.filter( ':not(:last-child)' ).addClass( 'arrow' ).find( 'div' ); // Execute when complete page is fully loaded, including all frames, objects and images - $( window ).load( function () { + $( window ).on( 'load', function () { arrowWidth = parseInt( $el.outerHeight(), 10 ); $stepDiv.css( paddingSide, arrowWidth.toString() + 'px' ); } ); @@ -80,7 +80,7 @@ $.each( $steps, function ( i, step ) { var $step = $( step ); if ( $step.is( selector ) ) { - if ($previous) { + if ( $previous ) { $previous.addClass( 'tail' ); } $step.addClass( 'head' );