r105276 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r105275‎ | r105276 | r105277 >
Date:05:16, 6 December 2011
Author:yaron
Status:ok
Tags:
Comment:
Revert of r104210 - all cases of "else if" in this file were in Javascript, which doesn't have an "elseif"
Modified paths:
  • /trunk/extensions/FCKeditor/FCKeditor.body.php (modified) (history)

Diff [purge]

Index: trunk/extensions/FCKeditor/FCKeditor.body.php
@@ -462,7 +462,7 @@
463463
464464 if ( !( typeof(oDoc.FCK) == "undefined" ) && !( typeof(oDoc.FCK.EditingArea) == "undefined" ) ){
465465 txtarea = oDoc.FCK.EditingArea.Textarea;
466 - } elseif( oDoc.editform ){
 466+ } else if( oDoc.editform ){
467467 // if we have FCK enabled, behave differently...
468468 if ( showFCKEditor & RTE_VISIBLE ){
469469 SRCiframe = oDoc.getElementById( 'wpTextbox1___Frame' );
@@ -498,7 +498,7 @@
499499 // save window scroll position
500500 if ( oDoc.documentElement && oDoc.documentElement.scrollTop )
501501 var winScroll = oDoc.documentElement.scrollTop;
502 - elseif ( oDoc.body )
 502+ else if ( oDoc.body )
503503 var winScroll = oDoc.body.scrollTop;
504504
505505 // get current selection
@@ -519,10 +519,10 @@
520520 // restore window scroll position
521521 if ( oDoc.documentElement && oDoc.documentElement.scrollTop )
522522 oDoc.documentElement.scrollTop = winScroll;
523 - elseif ( oDoc.body )
 523+ else if ( oDoc.body )
524524 oDoc.body.scrollTop = winScroll;
525525
526 - } elseif ( txtarea.selectionStart || txtarea.selectionStart == '0' ){ // Mozilla
 526+ } else if ( txtarea.selectionStart || txtarea.selectionStart == '0' ){ // Mozilla
527527
528528 // save textarea scroll position
529529 var textScroll = txtarea.scrollTop;
@@ -536,7 +536,7 @@
537537 if( !selText ){
538538 selText = sampleText;
539539 isSample = true;
540 - } elseif( selText.charAt(selText.length - 1) == ' ' ){ //exclude ending space char
 540+ } else if( selText.charAt(selText.length - 1) == ' ' ){ //exclude ending space char
541541 selText = selText.substring(0, selText.length - 1);
542542 tagClose += ' ';
543543 }
@@ -560,7 +560,7 @@
561561 if( !selText ) {
562562 selText = sampleText;
563563 isSample = true;
564 - } elseif( selText.charAt(selText.length - 1) == ' ' ) { //exclude ending space char
 564+ } else if( selText.charAt(selText.length - 1) == ' ' ) { //exclude ending space char
565565 selText = selText.substring(0, selText.length - 1);
566566 tagClose += ' '
567567 }
@@ -591,7 +591,7 @@
592592 // Remove the mwSetupToolbar onload hook to avoid a JavaScript error with FF.
593593 if ( window.removeEventListener )
594594 window.removeEventListener( 'load', mwSetupToolbar, false );
595 - elseif ( window.detachEvent )
 595+ else if ( window.detachEvent )
596596 window.detachEvent( 'onload', mwSetupToolbar );
597597 mwSetupToolbar = function(){ return false ; };
598598

Past revisions this follows-up on

RevisionCommit summaryAuthorDate
r104210"else if" -> "elseif"reedy00:20, 25 November 2011

Status & tagging log