r81836 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r81835‎ | r81836 | r81837 >
Date:19:10, 9 February 2011
Author:neilk
Status:deferred
Tags:
Comment:
simplified logic around selected step hiding/showing
Modified paths:
  • /trunk/extensions/UploadWizard/resources/mw.UploadWizard.js (modified) (history)

Diff [purge]

Index: trunk/extensions/UploadWizard/resources/mw.UploadWizard.js
@@ -1749,18 +1749,12 @@
17501750 // the step's contents
17511751 var stepDiv = $j( '#mwe-upwiz-stepdiv-' + stepName );
17521752
1753 - if ( _this.currentStepName === stepName ) {
1754 - stepDiv.hide();
1755 - // we hide the old stepDivs because we are afraid of some z-index elements that may interfere with later tabs
1756 - // this will break if we ever allow people to page back and forth.
 1753+ if ( selectedStepName === stepName ) {
 1754+ stepDiv.show();
17571755 } else {
1758 - if ( selectedStepName === stepName ) {
1759 - stepDiv.hide();
1760 - } else {
1761 - stepDiv.show( 1000 );
1762 - }
 1756+ stepDiv.hide();
17631757 }
1764 -
 1758+
17651759 } );
17661760
17671761 $j( '#mwe-upwiz-steps' ).arrowStepsHighlight( '#mwe-upwiz-step-' + selectedStepName );

Status & tagging log