From: Leo Koppelkamm Date: Wed, 6 Jul 2011 12:29:56 +0000 (+0000) Subject: Revert r86047 for now per CR. X-Git-Tag: 1.31.0-rc.0~29049 X-Git-Url: https://git.cyclocoop.org/%7B%24www_url%7Dadmin/compta/banques/?a=commitdiff_plain;h=91c38e63da79e1bf426907f052e156140716e653;p=lhc%2Fweb%2Fwiklou.git Revert r86047 for now per CR. --- diff --git a/resources/mediawiki.action/mediawiki.action.history.js b/resources/mediawiki.action/mediawiki.action.history.js index 06fb4cceeb..1b5b3a00a7 100644 --- a/resources/mediawiki.action/mediawiki.action.history.js +++ b/resources/mediawiki.action/mediawiki.action.history.js @@ -48,45 +48,6 @@ jQuery( function( $ ) { return true; }; - var fixCompare = function () { - var $diffList = $( '#pagehistory' ), - $histForm = $( '#mw-history-compare' ), - $buttons = $histForm.find( 'input.historysubmit' ); - - // There's only one rev, nothing to do here - if ( !$buttons.length ) { - return false; - } - var copyAttrs = ['title', 'accesskey']; - $buttons.each(function() { - var $button = $(this), - $compareLink= $( '', { - 'class': 'compare-link', - 'text': $button.val() - }).button(); - $.each( copyAttrs, function( i, name ) { - var val = $button.attr( name ); - if (val) { - $compareLink.attr( name, val ); - } - }); - $button.replaceWith( $compareLink ); - }); - var updateCompare = function() { - var $radio = $histForm.find( 'input[type="radio"]:checked' ); - var genLink = mw.config.get( 'wgScript' ) - + '?title=' + mw.util.wikiUrlencode( mw.config.get( 'wgPageName' ) ) - + '&diff=' + $radio.eq(0).val() - + '&oldid=' + $radio.eq(1).val(); - $( '.compare-link' ).each( function() { - $(this).attr('href', genLink); - }); - } - updateCompare(); - $diffList.change( updateCompare ); - }; - $( '#pagehistory li input[name="diff"], #pagehistory li input[name="oldid"]' ).click( updateDiffRadios ); - fixCompare(); updateDiffRadios(); }); \ No newline at end of file