r104460 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r104459‎ | r104460 | r104461 >
Date:17:34, 28 November 2011
Author:yaron
Status:deferred
Tags:
Comment:
Partial revert of r104210 - most of the instances of "else if" in this file were in Javascript, which doesn't have an "elseif"
Modified paths:
  • /trunk/extensions/SemanticForms/includes/SF_FormUtils.php (modified) (history)

Diff [purge]

Index: trunk/extensions/SemanticForms/includes/SF_FormUtils.php
@@ -489,7 +489,7 @@
490490 if (x.currentStyle) {
491491 // IE
492492 var y = x.currentStyle['lineheight'];
493 - } elseif (window.getComputedStyle) {
 493+ } else if (window.getComputedStyle) {
494494 // FF, Opera
495495 var y = document.defaultView.getComputedStyle(x,null).getPropertyValue('line-height');
496496 }
@@ -535,7 +535,7 @@
536536 {
537537 txtarea = oDoc.FCK.EditingArea.Textarea ;
538538 }
539 - elseif (oDoc.editform)
 539+ else if (oDoc.editform)
540540 {
541541 // if we have FCK enabled, behave differently...
542542 if ( showFCKEditor & RTE_VISIBLE )
@@ -581,7 +581,7 @@
582582 //save window scroll position
583583 if ( oDoc.documentElement && oDoc.documentElement.scrollTop )
584584 var winScroll = oDoc.documentElement.scrollTop ;
585 - elseif ( oDoc.body )
 585+ else if ( oDoc.body )
586586 var winScroll = oDoc.body.scrollTop ;
587587
588588 //get current selection
@@ -603,11 +603,11 @@
604604 //restore window scroll position
605605 if ( oDoc.documentElement && oDoc.documentElement.scrollTop )
606606 oDoc.documentElement.scrollTop = winScroll ;
607 - elseif ( oDoc.body )
 607+ else if ( oDoc.body )
608608 oDoc.body.scrollTop = winScroll ;
609609
610610 }
611 - elseif ( txtarea.selectionStart || txtarea.selectionStart == '0' )
 611+ else if ( txtarea.selectionStart || txtarea.selectionStart == '0' )
612612 { // Mozilla
613613
614614 //save textarea scroll position
@@ -624,7 +624,7 @@
625625 selText = sampleText ;
626626 isSample = true ;
627627 }
628 - elseif (selText.charAt(selText.length - 1) == ' ')
 628+ else if (selText.charAt(selText.length - 1) == ' ')
629629 { //exclude ending space char
630630 selText = selText.substring(0, selText.length - 1) ;
631631 tagClose += ' ' ;
@@ -653,7 +653,7 @@
654654 if (!selText) {
655655 selText = sampleText;
656656 isSample = true;
657 - } elseif (selText.charAt(selText.length - 1) == ' ') { //exclude ending space char
 657+ } else if (selText.charAt(selText.length - 1) == ' ') { //exclude ending space char
658658 selText = selText.substring(0, selText.length - 1);
659659 tagClose += ' '
660660 }

Past revisions this follows-up on

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